i dont want to use the XamComboEditor.
How can i implement that?
Thank you.
Hello Alex,
I did what you gave to use a wpf combobox in XamDataGrid's cell.
But I am not able to see the combobox items and it is looking like a textbox.
Can you help me this?
Thank you
thank you. That is exactly what I wanted.
and how can i bind the cell value to combobox selectedvalue?
You can put any control inside the XamDataGrid, it is as simple as creating a new style and control template. Here is some quick straightforward way of putting a combobox in the cell:
<igDP:Field Name="name">
<igDP:Field.Settings>
<igDP:FieldSettings>
<igDP:FieldSettings.CellValuePresenterStyle>
<Style TargetType="{x:Type igDP:CellValuePresenter}">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type igDP:CellValuePresenter}">
<ComboBox>
<ComboBox.Items>
<ComboBoxItem>1</ComboBoxItem>
<ComboBoxItem>2</ComboBoxItem>
<ComboBoxItem>3</ComboBoxItem>
</ComboBox.Items>
</ComboBox>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</igDP:FieldSettings.CellValuePresenterStyle>
</igDP:FieldSettings>
</igDP:Field.Settings>
</igDP:Field>
Using this, you can host any built-in/ user/ custom control.
We would really appreciate your feedback on the XamDataGrid and hosting other controls in it. You can request the feature(s) that you want to see in our future releases here and we will try to include them:
http://devcenter.infragistics.com/Protected/RequestFeature.aspx
I would like to see a better compatibility with MS ItemControls like ComboBox in the next release.
I extended ComboBox for my own functions and defined centralized combo styles and data templates for my comboboxes.
ich would like to use this as dropdown in XamDataGrid too.
This approach with hosted wpf controls is nice but this is not practical enough. I tested the xceed datagrid. There seems to be a better compatibility with WPF Controls.
Is it worth the wait for next release?
I do not have such sample right now, but you can look example in the XamFeatureBrowser of CVP retemplating as well as this blog post by Andrew Smith:
http://blogs.infragistics.com/blogs/andrew_smith/archive/2009/03/27/hosting-wpf-controls-in-a-xamdatagrid-cell.aspx