SciChart® the market leader in Fast WPF Charts, WPF 3D Charts, and iOS Chart & Android Chart Components

0
0

I am showing a dialog window with a ChartSurface in it. I have a context menu option to export to an image, and on window load I export to an XPS file. The dialog works fine if I do not use either feature, but once I do, I intermittently get an exception when showing the dialog. It appears to regularly take 3 instances of the dialog after the export feature is used to throw the exception, and the exception gets thrown twice the first time, threes times the second time, and so on. Again, if I do not use the export feature (no call to ExportToFile), I do not get any exceptions no matter how many times I show the dialog.

The exception message is “The provided DependencyObject is not a context for this Freezable. Parameter name: context”.

There are no other useful details in the exception from what I can see. Its all pretty abstract WPF stuff. The exported file/image seem to be generated accurately regardless of the exception.

I am using SciChart 4.2.2.9724, Visual Studio 2017 Professional, C#, WPF

Any ideas?

Version
4.2.2.9724
  • You must to post comments
0
0

Hi Jeremy,

I am fairly sure that this issue has been fixed in version 5.x of SciChart. However, I cannot tell for sure unless you test it.

Diagnosing complex bug reports like this requires three things: (see our Support Policy)

1.) That you are using the latest version of SciChart
2.) That your support is not expired (it shows as expired on our system)
3.) That you have provide a code sample such as a Visual Studio project to reproduce to the problem

Can you try out v5.x on the same code and see if it works? If YES then your solution is to upgrade. If NO then provide a code sample, and we will investigate, however, we won’t provide the fix to you with an expired support subscription.

Finally if our system is incorrect (you have a valid license) let me know and we will update.

Best regards,
Andrew

  • Jeramy Soucy
    I’ve downloaded 5.3.0 as a trial. When I rebuilt my code, instead of my usual charts I get a message saying my support subscription has expired and my license is only valid for earlier versions. How do I make use of demoing the newest version?
  • You must to post comments
0
0

I’m able to reproduce the issue, or a similar issue with version 5.4

What my code has is a “Start/Stop” button. When “Start” is pressed, the Axes are cleared and re-initialized.
If just using Start / Stop then it works, but if I export the chart into an image (a PNG in that matter), and after few seconds I click on the “Start”, then few seconds later, the software crash on the exception mentioned above.

From what I’ve been able to debug, the Export to image create a new chart control with all the bindings, and renders it to an image.
When I click on start, then the Axis (in this case, I see that the Y Axes are the ones that cause it) are cleared and created in my view model, and therefore it also affects the chart.
The binding of the chart that was created for the rendering is probably not cleared, so it gets the change event after some time, and Arrange is being called.

I see that ArrangeOverride on the AxisPanel is called, and _axisTitle,Arrange is called at this point the application crashes.

Please fix it.

  • You must to post comments
Showing 2 results
Your Answer

Please first to submit.

SciChart WPF v6 BETA released! Note pricing/licensing changes are coming. Contact us to beat the rise!Read more
+