Quantcast
Channel: wpftoolkit Discussions Rss Feed
Viewing all articles
Browse latest Browse all 2157

New Post: Editable combobox problem

$
0
0
I'm trying to build an editable combobox. This combobox in a datagrid. Binding is made with MVVM.
Everything works well except this : after typing a new value, this value is lost when going out of the combo.

Here is my code :
<xcdg:Column FieldName="FlangeType"  Title="Flange Type"  Width="80" >

    <xcdg:Column.CellEditor>
          <xcdg:CellEditor>
                <xcdg:CellEditor.EditTemplate>
                       <DataTemplate>
                            <ComboBox
                                            ItemsSource="{Binding Path= DataContext.FlangeTypes, RelativeSource={RelativeSource AncestorType={x:Type UserControl}}}" 
                                            SelectedValue="{xcdg:CellEditorBinding}"
                                            Text="{Binding Path=DataContext.CurrentDrumStandard.FlangeType,UpdateSourceTrigger=LostFocus}"
                                            IsEditable="True"/>
                         </DataTemplate>
                    </xcdg:CellEditor.EditTemplate>
              </xcdg:CellEditor>
      </xcdg:Column.CellEditor>
                        
</xcdg:Column> 
Thanks in advance for any help.

Viewing all articles
Browse latest Browse all 2157

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>