Welcome to MSDN Blogs Sign in | Join | Help

Supporting the unsupported [Two fixes for the unofficial WPF Charting assembly!]

In my last post I described a few updates I made to my ChartBuilder sample/application/learning tool for the March 09 release of the Silverlight Toolkit. As usual, I posted the complete source code to ChartBuilder for interested parties to download and play around with. But this time around I also took the opportunity to showcase a WPF version of ChartBuilder that shows off an unofficial version of Silverlight Charting for WPF. Along with a WPF-based project file for ChartBuilder, I included a private build of the WPF Charting assembly that it compiles against.

I cautioned readers that WPF Charting was completely untested, but it was my not-so-secret hope that some of you would take the opportunity to play around with WPF Charting and give us some early feedback. And you did! :)

In addition to a known issue I describe in the previous post where dynamically added or removed DataPoints don't always complete their show/hide animations, kind reader abrien reported an additional problem causing a KeyNotFoundException during certain updates to a PieSeries's ItemsSource property. Then he/she went even further to create a CodePlex work item with a simple sample project demonstrating the problem! (Which is fantastic bug reporting, by the way!)

Now, before I go further, let me take this opportunity to reemphasize that neither of these problems is present in Silverlight Charting; they exist only in WPF Charting and are there because we've done absolutely no testing of WPF Charting due to a profound lack of time or resources. In fact, this is probably a good time to remind everyone of the warning I gave last time:

Warning: We have done absolutely no testing of the WPF Charting bits and if you decide to pull them out of the source code download and play around with them, then you do so at your own risk!

Okay, enough scare-mongering! :) The truth is that we'd love for people to be able to start experimenting with WPF Charting. So while the known show/hide problem was already bothering me, finding out about an exceptional condition arising from a fairly simple ChartBuilder scenario was downright unpleasant...

I spent some time over the weekend looking into both of these issues to see if I could identify the problem and perhaps fix it without too much fuss. And the good news is that I believe they're both fixed now! [After no small amount of frustration along the way... :) ] As it happens, both problems result from fairly subtle Storyboard behavior differences between Silverlight and WPF - though I'm happy to note the fixes I made are not platform specific. In other words, it's possible to write the exact same code on both platforms and have it work correctly on both platforms. It's just the code we started with wasn't that code... :(

I'm optimistic that both of these problems are behind us. And what's more, the fixes are already checked into our source control system for inclusion in the next release of Charting. But I don't want early adopters of WPF Charting to have to wait that long, so I've gone ahead and updated the WPF Charting assembly in the ChartBuilder download to include both of these fixes! If you're already playing around with WPF Charting, please take a moment to upgrade to the new version of System.Windows.Controls.DataVisualization.Toolkit.dll (file version 3.0.30324.1808) from the ChartBuilder download link below. And if you don't care about WPF Charting, then please don't worry about any of this - there are no other changes to the files in the download archive.

Our thanks go out to everyone who has given Silverlight Charting a try - and special thanks to our WPF Charting pioneers for their passion, feedback, and patience!

 

Please click here to download the complete ChartBuilder source code.

 

ChartBuilder on WPF
Published Wednesday, March 25, 2009 11:25 AM by Delay

Comments

# Delay's Blog : Supporting the unsupported [Two fixes for the unofficial WPF Charting assembly!]

# re: Supporting the unsupported [Two fixes for the unofficial WPF Charting assembly!]

Wednesday, March 25, 2009 10:00 PM by abrien

Whoo hoo! :) That's great news.

My project since last week at work has been to pull out reports from a database that stores our game's performance. Usually, we did this through php, ajax, html, flash, etc. But my tools team is most efficient and experienced in .NET so I decided to test out making the report in a WPF Browser App. I was so glad to find your post at the same time, that the Silverlight charting worked in WPF, because the only other thing I had found was the WinForms version.

It worked out great! The reports look really great, and I'm just amazed at how little code is behind it. I worked around the issue mentionned above simply by recreating the series instead of just replacing its ItemsSource. Other than that, the charting works really well with my WPF app. I use both Column and Line charts, I've styled the chart to get rid of the title and legend in some places. I push a ton of data to those charts and so far no issues.

Thanks for the quick update!

Anthony

# re: Supporting the unsupported [Two fixes for the unofficial WPF Charting assembly!]

Thursday, March 26, 2009 2:41 AM by Delay

Anthony,

Thanks for the kind words - I'm glad we could help your team out! :)

# Supporting the unsupported [Two fixes for the unofficial WPF Charting assembly!] - Delay's Blog

Thursday, March 26, 2009 8:02 AM by DotNetShoutout

Thank you for submitting this cool story - Trackback from DotNetShoutout

# If they can build it, they will come... [Enabling anyone to compile WPF Charting from the Silverlight Charting sources!]

Thursday, March 26, 2009 4:03 PM by Delay's Blog

In yesterday's post I updated the unsupported public build of WPF Charting . The WPF version of the System.Windows.Controls.DataVisualization.Toolkit.dll

# Silverlight Cream for March 27, 2009 -- #554

Friday, March 27, 2009 3:49 PM by Community Blogs

In this Issue: Jeff Prosise , Michael S. Scherotter , Kirupa Chinnathambi ( 2 ), Bryant Likes ( 2 , 3

# Another round of (un)support [Quick fix for the unofficial WPF Charting assembly!]

Wednesday, April 22, 2009 3:12 AM by Delay's Blog

When I updated my ChartBuilder sample/application/learning tool for the March 09 release of the Silverlight

Anonymous comments are disabled
 
Page view tracker