We recently upgraded from TChart.WPF 3.5.3700.30575 to 4.1.2013.05282. We face the following problem:
For some of our xy cartesian charts we add event handler methods for the event 'AfterDraw' to draw some custom graphics. Since upgrading to the new TChart, the following exception is thrown when zooming on a chart where 'AfterDraw' event handlers have been added:
"A first chance exception of type 'System.NullReferenceException' occurred in TeeChart.WPF.dll
Additional information: Object reference not set to an instance of an object."
We can reproduce it everytime. If we zoom on a chart where no 'AfterDraw' event handler method is added, all good. However, if we add 'AfterDraw' event handler methods, zooming on the chart causes the exception. I even made our 'AfterDraw' event handler method body empty (basically do nothing), and still zooming causes the exception.
Are you able to reproduce this on your side?
Exception when zooming on chart
Re: Exception when zooming on chart
Hello Magus,
Can you arrange for us a simple project, because we can reproduce your problem here and try to find a solution for you?
Thanks,
Can you arrange for us a simple project, because we can reproduce your problem here and try to find a solution for you?
Thanks,
Best Regards,
Sandra Pazos / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Exception when zooming on chart
Please find attached a small test program reproducing the bug.
If you zoom on the chart, TChart throws an exception. As soon as you remove the 'AfterDraw' event handler methods (See ChartUtils.cs in the attached project), no more crash.
Also, the Graphics3D object received in the 'AfterDraw' event handler method returns ''g.FontHeight' threw an exception of type 'System.NullReferenceException''.
If you zoom on the chart, TChart throws an exception. As soon as you remove the 'AfterDraw' event handler methods (See ChartUtils.cs in the attached project), no more crash.
Also, the Graphics3D object received in the 'AfterDraw' event handler method returns ''g.FontHeight' threw an exception of type 'System.NullReferenceException''.
- Attachments
-
- TChartTest.zip
- Test Project
- (18.25 KiB) Downloaded 391 times
Re: Exception when zooming on chart
Hello Magus,
Many thanks for your code. Finally, I have reproduced your problem and I have added it in bug list report with number[TW16016637]. We will try to fix it to upcoming maintenance releases of TeeChartFor.Net.
Thanks,
Many thanks for your code. Finally, I have reproduced your problem and I have added it in bug list report with number[TW16016637]. We will try to fix it to upcoming maintenance releases of TeeChartFor.Net.
Thanks,
Best Regards,
Sandra Pazos / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Exception when zooming on chart
Glad you reproduced the problem. When can we expect the next maintenance release?
Re: Exception when zooming on chart
Hello Magus,
I can not give you an estimate date but I recommend you to be aware at this forum, our RSS news feed, twitter and facebook accounts for new release announcements and what's implemented on them.
Thanks,
I can not give you an estimate date but I recommend you to be aware at this forum, our RSS news feed, twitter and facebook accounts for new release announcements and what's implemented on them.
Thanks,
Best Regards,
Sandra Pazos / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |