I have a xamWebchart bound to a collection in the view model. (I am following the MVVM pattern). However, when the collection changes the chart does not reflect the changes to the collection . I am setting RefreshEnabled to false before I change the collection and then setting it to true after the collection is changed, as explained in this post http://blogs.infragistics.com/forums/p/38206/219989.aspx#219989. However, my chart does not refresh and show the changes made to the collection. My dataSource implements INotifyCollectionChanged. Any help will be appreciated.
Pls. let me know, if I need to provide more info.
Hi,
Do you think you could provide a small code sample that replicates the issue? Some more details about how you are trying to set up the binding would help.
Thanks,
Graham
Hello,
Thank you for your post. I have been looking into it, but since I cannot be completely sure how your data is organized I wasn’t able to reproduce your behavior, so if this is still an issue for you, could you please send an isolated sample project, where the issue is reproduced, so I can investigate it further for you.
Looking forward for your reply.
I facing same problem with infragistics xamWebChart. When my observable collection changes chart does not change.
-------------------
<XXX>.Xaml.CS
.
<Viewbox Grid.Row="2" x:Name="vbIncidentStatus" Visibility="{Binding Path=IncidentStatusData, Converter={StaticResource StatusDataConverter}}" > <igChart:XamWebChart x:Name="igPieChart_IncidentStatus" Height="100" RefreshEnabled="True"> <igChart:XamWebChart.Scene> <igChart:Scene Margin="-50,-20,-20,-20" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch"></igChart:Scene> </igChart:XamWebChart.Scene> <igChart:XamWebChart.Series> <!--DataMapping="Label=ToolTip; Value=CaseCount; ToolTip=ToolTip; Fill=SeverityGraphBrush"--> <igChart:Series ChartType="Doughnut" DataSource="{Binding IncidentStatusData}" DataMapping="Value=CaseCount;Label=ToolTip;ToolTip=ToolTip" Stroke= "White" Loaded="Series_Loaded"> </igChart:Series> </igChart:XamWebChart.Series> <igChart:XamWebChart.Legend> <igChart:Legend Width="0" Visibility="Collapsed"></igChart:Legend> </igChart:XamWebChart.Legend> </igChart:XamWebChart> </Viewbox>
---------------------
<xxxViewModel>.cs
ObservableCollection<IncidentStatusData> _data = new ObservableCollection<IncidentStatusData>(); int osrCount = 0; foreach (GetIncidentStatusResponseList itemIncStatus in incstatusDataCollection) { IncidentStatusData _singleData = new IncidentStatusData(); _singleData.SeverityLevel = itemIncStatus.SeverityLevel; _singleData.CaseCount = itemIncStatus.CaseCount; _singleData.ToolTip = itemIncStatus.SeverityLevel + " (" + itemIncStatus.CaseCount + ")"; _singleData.SeverityGraphBrush = OISUtility.OISColours.getSeverityGraphBrush(itemIncStatus.SeverityLevel); _data.Add(_singleData); osrCount = osrCount + (int)itemIncStatus.CaseCount; } this.IncidentStatusModel.IncidentStatusData = _data;
-----------------------
Kindly suggest me solution for this issue.