开发者

Updating ASP.NET chart asynchronously

开发者 https://www.devze.com 2022-12-09 02:36 出处:网络
开发者_开发百科Is there any way to update one of these charts asynchronously besides calling Chart1.SaveImage() and sending the image URL to the client-side?If you use javascript the browser can ask i
开发者_开发百科

Is there any way to update one of these charts asynchronously besides calling Chart1.SaveImage() and sending the image URL to the client-side?


If you use javascript the browser can ask if there is an update to the chart, and if there is, it could just change the url for the image, by changing the datetime on it:

<img src=myimage.aspx?datetime=884733 />

This would then get the latest chart as you send the data directly to the image tag.

This would enable the server to decide if a new image should be generated, or to use the already created one. You could also add some user info such as the current date/time to the chart before sending it out.

0

精彩评论

暂无评论...
验证码 换一张
取 消