ASE Home Page Products Download Purchase Support About ASE
ChartDirector General
Forum HomeForum Home   SearchSearch

Message ListMessage List     Post MessagePost Message

  IMG of chartdirector
Posted by jennis on Mar-29-2011 14:44
i have just installed chartdirector for showing some graphs on my website.
want to know which is the directory where the graphs images will be generated by chartdirector. i have to mention the same in my asp page.

  Re: IMG of chartdirector
Posted by Peter Kwan on Mar-30-2011 01:39
Hi jennis,

ChartDirector does not need a directory to store the graph images. It can stream the image directly to the browser, or it may store the image in memory.

For example, in the "Simple Bar Chart" sample code, the chart is streamed directly to the browser, like:

<IMG SRC="simplebar.asp">

However, if you for some reasons want to store the chart image in the hard disk, you may use either BaseChart.makeChart or BaseChart.makeTmpFile. For example:

'Save the chart as a temporary file in Server.MapPath("/tmpcharts"). Please make sure
'the web server anonymous user has read/write access to that directory
filename = c.makeTmpFile(Server.MapPath("/tmpcharts"))

Now you can use the temporary file in your image tag:

<IMG SRC="/tmpcharts/<%=filename%>">

Hope this can help.

Regards
Peter Kwan