Hi,
The changes done in the CollectionControl are saved in the source when the OK button from the CollectionControlDialog is pressed.
You can save the changes by calling CollectionControl.PersistChanges() when items are added, deleted...
private void CollectionControl_Action( object sender, Xceed.Wpf.Toolkit.ItemEventArgs e )
The changes done in the CollectionControl are saved in the source when the OK button from the CollectionControlDialog is pressed.
You can save the changes by calling CollectionControl.PersistChanges() when items are added, deleted...
<xctk:PropertyGrid.EditorDefinitions><xctk:EditorTemplateDefinition TargetProperties="People">
<xctk:EditorTemplateDefinition.EditingTemplate>
<DataTemplate>
<xctk:CollectionControl ItemsSource="{Binding Value}"
ItemAdded="CollectionControl_Action"
ItemDeleted="CollectionControl_Action"
ItemMovedDown="CollectionControl_Action"
ItemMovedUp="CollectionControl_Action"/>
</DataTemplate>
</xctk:EditorTemplateDefinition.EditingTemplate>
</xctk:EditorTemplateDefinition>
</xctk:PropertyGrid.EditorDefinitions>private void CollectionControl_Action( object sender, Xceed.Wpf.Toolkit.ItemEventArgs e )
{
var collectionControl = sender as CollectionControl;
if( collectionControl != null )
{
collectionControl.PersistChanges();
}
}