Hi,
I'm using a XamChart to show some data which periodically changes, binding to a collection whose elements implement INotifyPropertyChanged.This is the code I wrote:
<igCA:Series Label="Patient Height" ChartType="Column" DataSource="{Binding Source={StaticResource PatientData}}" DataMapping="Value = Height; Label = Name" />
With this code, the chart doesn't receive any change notification and it is never updated.After one day of investigation, I found out that the DataMapping property has to be written with Label first and then Value, as in the following line:
<igCA:Series Label="Patient Height" ChartType="Column" DataSource="{Binding Source={StaticResource PatientData}}" DataMapping="Label = Name; Value = Height" />
No ordering of the couples inside the DataMapping property is specified in the help,is it a bug or something is missing in the documentation?
If the data changes dynamically, you may need to change StaticResource to DynamicResource:
DataSource
If that doesn't work, there may be a bug. If so, please report the defect at our developer support site and request a work-around:
http://www.infragistics.com/gethelp/
I tried changing StaticResource to DynamicResource and I got the following XamlParseException:
A 'DynamicResourceExtension' cannot be set on the 'Source' property of type 'Binding'. A 'DynamicResourceExtension' can only be set on a DependencyProperty of a DependencyObject.
However, it is working perfectly with StaticResource even with dynamic data according that I write
DataMapping="Label = Name; Value = Height"
instead of
DataMapping="Value = Height; Label = Name"