I have a page with many charts and grids and there is a significant load time. Therefore I need to put up a "please wait" lightbox until everything is shown properly. When the page first presents itself I see a vertical line and a few seconds later the chart is displayed in it's full glory. Is there an event thrown that I can get at when the chart is finally displayed, instead of when it first is drawn as a vertical line? i need this so that I can remove the "please wait" notification.
are you using the XamChart control or the XamDataChart?
in either case, the LayoutUpdated event is useful for this, although it is raised more times than you will need it.
depending on which chart control you are using, there may be a more precise way.
I am using the xamChart. If it is raised multiple times, is there a way to know which one is the final one?
Thanks. I found a way around the problem. I hooked onto the SizeChanged event and when the size is > 100 I assume that everything is there. It has worked so far. Not elegant, but sometimes in programming you have to go with the dirty solution that works.
there isn't an event designed for this purpose, so i started looking for the right condition to evaluate in LayoutUpdated. however, when i tested this out using this code:
<UserControl.Resources>
<local:Data x:Key="data" />
</UserControl.Resources>
<Grid x:Name="LayoutRoot" Background="White">
<igChart:XamWebChart Name="theChart" LayoutUpdated="XamWebChart_LayoutUpdated">
<igChart:XamWebChart.Series>
<igChart:Series ChartType="Column" DataSource="{StaticResource data}" DataMapping="Value=Value" />
</igChart:XamWebChart.Series>
</igChart:XamWebChart>
</Grid>
...the LayoutUpdated event was only raised once.
do you have steps to reproduce or a sample app to reproduce the problem you're experiencing?