Deploying MS Chart control sites
June 30, 2009 | In Development |Having created a new site on my development machine using the MS Charting controls (see my previous post here) I published to my test server. I found two things that must be rememered when doing this.
First up you will need the System.Web.DataVisualization assembly on the server, else you will receive an ‘assembly not found’ error (that one’s obvious really). This is installed from the MSChart.exe (Microsoft Chart Controls for Microsoft .NET Framework 3.5). I believe the assembly is to included in the .NET Framework 4 by default.
The second is that an entry is created in your web.config file for storage of the temporary images that are used to display the charts. This needs to be changed to that of a directory that you have write permission for. The default is set to whichever drive you were originally developing on. I’d suggest setting to a physical path somewhere inside the website root. You will need to find the absolute path for this using something like Server.MapPath (if you don’t know it already).