MS Chart 未显示在托管网站上
我有一个 MS Chart 组件在 ASP.Net 页面上显示良好。当我部署它时,我得到了一个损坏的图像。 web.config 中的设置相同,并且临时图像文件夹具有正确的权限。
当我获取图像的 URL 时,我可以看到 /.png 文件没有被创建。
我需要注意哪些事项才能找出问题所在?
I have a MS Chart component displaying fine on an ASP.Net page. When I deploy it I get a broken image. The settings in the web.config are the same and the temporary images folder has the correct permissions.
When I get the URL of the images I can see that the /.png file is not getting created.
What sort of things do I need to look at to track down the problem?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
通过确保我的应用程序池设置使用“ASP .net 集成”而不是“ASP .Net Classic”,我能够解决该问题。这将确保您的处理程序正在被使用。
I was able to resolve the issue by ensuring that my application pool settings was using "ASP .net integrated" and not "ASP .Net Classic". This will ensure that your handler is being used.
当我在 .NET 4 中使用图表时,我遇到了同样的问题,我的问题与 privateImages 属性的默认值以及我的代码没有使用会话或会话的任何标识属性这一事实有关。用户。
请参阅我的帖子此处,了解我如何进行操作的说明解决了我的问题。
还值得注意的是,ASP.NET 开发服务器会忽略图表的配置设置并将它们呈现在内存中,除非您专门设置一个属性来强制它使用您的配置。
I had the same problem when I was working with the charting in .NET 4 and my problem turned out to be related to the default value of the privateImages attribute and the fact that my code wasn't using any identifying attributes for the session or the user.
See my post here for an explanation of how I solved my problem.
It's also worth noting that the ASP.NET Development server ignores the config settings for charting and renders them in memory unless you specifically set an attribute to force it to use your config.