This is a migrated thread and some comments may be shown as answers.

Error Loading Radchart Image

1 Answer 196 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
Malik
Top achievements
Rank 1
Malik asked on 23 Jul 2013, 05:56 PM
Hi,
I am using Radchart Control for Chart reporting. I am getting error while Loading Radchart Image.One of the Folder which is under the Login is going correct and loading chart successfully but the other one which is outside not working please need help.. Ongoing Project.


Regards.

1 Answer, 1 is accepted

Sort by
0
Petar Kirov
Telerik team
answered on 26 Jul 2013, 01:54 PM
Hi Malik,

Here is how RadChart works. When the page request is processed on the server, an image is created and saved in the session or in the TempImages folder, while an <img> tag is rendered in the page. The value of its ImgSrc attribute looks similar to this:
ChartImage.axd?UseSession=true&ChartID=26ebed38-fa6a-4aa8-8840-3cf1d770b4e8_chart_RadChart1&imageFormat=Png&random=084ed189-0e3c-47b3-8fad-83892cbf4202

When the browser requests the image, the ChartHttpHandler is responsible for retrieving the image from the session state and for serving it to the client. It also deletes the image from the session / filesystem and puts it in the cache with 5 minutes expiration time.

There might be different reasons for the error that you are getting:
  • ChartHttpHandler is not configured correctly -- the problem will be persistent
  • Output caching with expiration time larger that 5 minutes is deployed. Possible problems are described in this forum post.
  • The image request is not processed by the machine, which has processed the page request . The solution here would be to implement State server or SQL server session state mode or sticky session, ensuring that all the requests from one user will be handled by the same machine.

An alternative solution involves disabling the session state usage for the chart. In this case you will need to provide a shared folder accessible from all the machines in the web farm and map it as a virtual directory within your web application. Then set this folder as TempImagesFolder.
 
Regards,
Petar Kirov
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
Tags
Ajax
Asked by
Malik
Top achievements
Rank 1
Answers by
Petar Kirov
Telerik team
Share this question
or