Home Forums WPF controls Xceed DataGrid for WPF combo box CellEditor

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • User (Old forums)
    Post count: 23064
    #24680 |

    Hopefully this will be obvious to someone. I’ve got a combo box cell editor that I use in my CardView. Everything works ok with it except that after selecting one of the options in the combo and moving focus elsewhere in the application, the selected value is reset back to the original binding value, no matter which option I select. Here is the XAML for my editor:

    <xcdg:CellEditor x:Key=”statusEditor”>
    <ComboBox Grid.Row=”2″ BorderThickness=”1″ MinHeight=”22″
    ItemsSource=”{Binding Source={x:Static Application.Current},Path=Status}”
    <Style TargetType=”Popup”>
    <Setter Property=”TextElement.Foreground” Value=”{DynamicResource {x:Static SystemColors.WindowTextBrushKey}}” />
    <xcdg:KeyActivationGesture SystemKey=”Down”
    <xcdg:KeyActivationGesture Key=”Up”
    <xcdg:KeyActivationGesture Key=”F4″/>
    <xcdg:KeyActivationGesture Key=”Space”/>

    Does anyone have an idea why this is happening?

    Imported from legacy forums. Posted by brent (had 561 views)

    Xceed Support
    Post count: 5658

    In your cell editor you have to bind the SelectedValue of the ComboBox to the Cell’s content…

    This can be done by using the “{xcdg:CellEditorBinding}” markup extension…

    You can refer to <a href=”http://doc.xceedsoft.com/products/XceedWpfDataGrid/Custom%20Cell%20Editors.html”>this article for more details</a>.

    Imported from legacy forums. Posted by Marcus [Xceed] (had 2810 views)

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.