asp.net中的水晶报表错误(加载报表失败) [英] Crystal report error (Load report failed) in asp.net

查看:87
本文介绍了asp.net中的水晶报表错误(加载报表失败)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

亲爱的所有人,

我目前正在从事采购项目,我正在使用Visual Studio-2010和SAP-Crystal Report for Visual Studio-2010 for Crystal Report,并且正在此网站上使用ASP.Net 4.0.

当我编写代码时,当我从Visual Studio中运行它时,它运行良好,并且看起来一切正常.

但是,当我将代码托管在本地计算机的IIS上并且访问链接时,Crystal Report不起作用时它说:"Load Report Failed",我尝试搜索许多内容,并尝试清空C:\ windows \ temp文件夹,我也尝试使用下面的代码:

Dear All,

I am currently working on project of Purchase, I am using Visual Studio-2010 and SAP-Crystal Report for Visual Studio - 2010 for Crystal Report , I am using ASP.Net 4.0 for this website.

When i made the code,it was working fine when i run it from visual studio and seems everything fine.

But when i hosted the code on my local machine''s IIS and when i visit the link the Crystal Report doesn''t works it says :"Load Report Failed", i tried searching many things, i tried emptying C:\windows\temp folder , i also tried using the below code:

public static ReportDocument rep = new ReportDocument();
   protected void Page_UnLoad(object sender, EventArgs e)
   {
       this.CrystalReportViewer1.Dispose();
       this.CrystalReportViewer1 = null;
       rep.Close();
       rep.Dispose();
       GC.Collect();
   }


但是我无法解决错误.请帮助我解决错误.
我真的被困住了.

预先感谢,
问候,
Krunal Panchal


but i am not able to solve the error . Please help me out in resolving the error.
I am really stucked up.

Thanks in advance,
Regards,
Krunal Panchal

推荐答案

确保程序可以找到水晶报表并且其路径可被其识别.
Make sure the program can find the crystal report and its path is recognizable by it.


尝试定位报告文件位于bin文件夹下.
加载(bin/.../Reports.rpt)
try to locate the reports file under bin folder.
Load(bin/.../Reports.rpt)


这篇关于asp.net中的水晶报表错误(加载报表失败)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆