6

The default location:

<add key="ChartImageHandler" value="storage=file;timeout=20;dir=c:\TempImageFiles\;" />

is fine for development, but not so good for deploying on IIS. I found a forum post that mentioned you could drop the path altogether, which dumps the temp file(s) directly in the root of my project

<add key="ChartImageHandler" value="storage=file;timeout=20;" />

I don't want to clutter up my root folder though, so I am settling on this for now:

<add key="ChartImageHandler" value="storage=file;timeout=20;url=~/App_Data/ChartImageTemp/;" />

Thoughts or what are other people doing? I'm a little curious as to why this is even a configurable option. I am using .net 3.5, maybe this is different in 4.0?

1 Answer 1

12

A related question:

MSChart: ChartImageHandler pros/cons of the different storage settings

Pointed me to an article by Scott Mitchell:

https://web.archive.org/web/20201205231110/https://www.4guysfromrolla.com/articles/081909-1.aspx

I've decided to use the "memory" option, so no files or paths to configure:

   <appSettings> 
      <add key="ChartImageHandler" value="storage=memory;deleteAfterServicing=true;"/> 
   </appSettings>
5
  • If you use web gardens, you're supposed to use file storage, but the control is buggy and doesn't really support web gardens regardless.
    – Greg
    Nov 24, 2010 at 14:34
  • Good to know, but we have one production web server and one production db server here :) Nov 24, 2010 at 14:41
  • 1
    Web Gardens is kind of a "web farm on a single server". You just open up the IIS admin and select the # of processes you want to run.
    – Greg
    Nov 24, 2010 at 14:43
  • 1
    Isn't there a problem using memory option if you choose to print the charts? I believe that some versions of IE won't print them.
    – chris
    Nov 24, 2010 at 15:20
  • Prints OK on IE8. With IE6, might have to set deleteAfterServicing to false social.msdn.microsoft.com/Forums/en/MSWinWebChart/thread/… Nov 24, 2010 at 17:57

Your Answer

Reminder: Answers generated by Artificial Intelligence tools are not allowed on Stack Overflow. Learn more

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.