Hello,
We've been working with the XamDataGrid and backing it with a ObservableCollection of DependencyObjects. When the grid is initialized all of the values are populated correctly. However, if one of the dependency objects has a property updated the corresponding record is not updated. I've attached a test project that demonstrates the behavior. Is there something wrong with the way that we are using the grid? If so, could you let me know how to configure my field layout to bind correctly to dependency properties.
Thanks,
Kayla
Hello Kayla,
If you don't want to use the INotifyPropertyChnaged interface, I can suggest you use UnboundFields instead of Fields in the XamDataGrid. For the Value Property yo ucan use the following definition of the UnboundField:
<igDP:UnboundField xmlns:sys="clr-namespace:System;assembly=mscorlib" BindingPath="Value" Label="Value" DataType="{x:Type sys:Int32}"/>
Please let me know if this helps you or you need further assistance on this matter.
Looking forward for your reply.
In our case we would like to take advantage of the performance gains provided by using DependencyObject and the DependencyProperty notification mechanisms. When using the System DataGrid my implementation is fine, it is only when I switch to using the XamDataGrid that notifications fail to update the grid values. Please let me know what it would take to use DependencyObjects as the DataItem for a DataRecord.
Thank you for your post. I have been looking into it and the sample you have uploaded and I modified it, so now it works as you want. Basically I implemented INotifyPropertyChnaged interface in the GridREcord class, so the XamDataGrid could be notified when the data changes.
http://msdn.microsoft.com/en-us/library/system.componentmodel.inotifypropertychanged(v=vs.110).aspx