DotNetCharting exception thrown

I am using DotNetCharting version 4.2. I am trying to create a chart, save it to disk and return the path as a string. Here is a simplified version of my code thus far.

Chart aChart = new Chart();
aChart aChart.Title = "Some Title";
aChart aChart.ChartArea.Background = new Background(Color.White);

aChart.TempDirectory = "C:\\temp\\"
aChart.Width = chartWidth;
aChart.Height = chartHeight;

imageName = aChart.FileManager.SaveImage();

I got this from this dotnetCharting support page. It is very straightforward code.

Here is the problem: The code above actually DOES create an image in the appropriate directory. This is NOT a directory permissions issue. When I add my actual data to the aChart, it actually DOES add it and an image is created. However, the SaveImage() method always throws an exception of "Failed to map the path '/'." The SaveImage() method is supposed to return a String, however, it always returns "" and the exception is thrown.

More Info: I am doing this in a WCF Service. Is it possible that since it's in a service the dotNetCharting DLL is having trouble with some internal MapPath?

Answers


I just upgraded the DotNetCharting to the latest version (7.0) and now it works fine. I believe that it was an issue with the old version of the DLL. I'll leave this here in case anyone else has this issue.


Need Your Help

Cannot access a property or method of a null object - Won't display codeline

xml actionscript-3 testing typeerror

I'm having a problem with the same old TypeError #1009: Cannot acces a property or a method of a null object reference.

a program that finds a function on a javascript webpage and run that in a loop

javascript google-chrome-extension firefox-addon firefox-addon-sdk add-on

So I'm trying to write a program that finds a java script function in a webpage (the page is written in java script) and a loop that runs the function until the user pushes a button.

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.