Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
75
XamDoughnutChart Object reference not set to an instance of an object when resizing
posted

Hello,

I have a Xam Doughnut Chart that after reloading data after a few times, causes the application to crash. I've been trying to debug for quite some time but i haven't found the issue until i looked into the call stack that showed where it might be blowing up, but I dont know whats causing it. 

Code

                                <ig:XamDoughnutChart x:Name="CurrentAccountChart"
                                    Grid.Column="0"
                                    InnerExtent="70">
                                    <ig:XamDoughnutChart.Series>
                                        <ig:RingSeries x:Name="CurrentAccountRingSeries"
                                            FormatLabel="CurrentAccountRingSeries_FormatLabel"
                                            ItemsSource="{Binding CurrentAccountBySeniority}"
                                            LabelExtent="15"
                                            LabelMemberPath="ValueLabel"
                                            LabelInnerColor="#51667a"
                                            LabelOuterColor="#51667a"
                                            LabelsPosition="OutsideEnd"
                                            LeaderLineType="Straight"
                                            LeaderLineVisibility="Visible"
                                            Legend="{x:Reference CurrentAccountLegend}"
                                            LegendLabelMemberPath="Label"
                                            RadiusFactor="0.6"
                                            StartAngle="150"
                                            ValueMemberPath="ValueLabel" />
                                    </ig:XamDoughnutChart.Series>
                                </ig:XamDoughnutChart>
                                
                                <ig:ItemLegend x:Name="CurrentAccountLegend"
                                    Grid.Column="1"
                                    HorizontalOptions="EndAndExpand"
                                    VerticalOptions="EndAndExpand" />

Call Stack with Exception

Parents
No Data
Reply
  • 29105
    Offline posted

    Hello and thank you for contacting Infragistics. First try unhooking FormatLabel and see if that is causing it. It's possible it's trying to format something that isn't available anymore (perhaps a timing issue). Please provide the code used to reload the data. Are you refreshing CurrencyAccountBySeniority? A sample isolating the behavior would very much help seeing how this is the first we're hearing about this issue. 

Children