水晶报表 - COMException (0x800003e5): 打开报表失败

1 操作:点击打印按钮(打印GridView列表中的记录)

2 错误信息:

================================================================================================
 
"/"应用程序中的服务器错误。
--------------------------------------------------------------------------------
打开报表失败。 
说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。 

异常详细信息: System.Runtime.InteropServices.COMException:打开报表失败。

源错误: 

执行当前 Web 请求期间生成了未处理的异常。可以使用下面的异常堆栈跟踪信息确定有关异常原因和发生位置的信息。  

堆栈跟踪: 


[COMException (0x800003e5): 打开报表失败。]
   CrystalDecisions.ReportAppServer.ClientDoc.ReportClientDocumentClass.Open(Object& DocumentPath, Int32 Options) +0
   CrystalDecisions.ReportAppServer.ReportClientDocumentWrapper.Open (Object& DocumentPath, Int32 Options) +77
   CrystalDecisions.ReportAppServer.ReportClientDocumentWrapper.EnsureDocumentIsOpened() +218

[Exception: 加载报表失败。]
   CrystalDecisions.ReportAppServer.ReportClientDocumentWrapper.EnsureDocumentIsOpened() +273
   CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String filename, OpenReportMethod openMethod, Int16 parentJob) +875 
   CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String filename) +52
   Report.Web.Report_Ord_Tihuodan.Page_Load(Object sender, EventArgs e) in f:/application/web/erpreport/web/report_ord_tihuodan.aspx.cs:89 
   System.Web.UI.Control.OnLoad(EventArgs e) +67
   System.Web.UI.Control.LoadRecursive() +35
   System.Web.UI.Page.ProcessRequestMain() +750

==========================================================================================================

3 解决过程

3.1 修改注册表

HKEY_LOCAL_MACHINE->SOFTWARE->Crystal Decisions->10.2->Report ApplicationServer->Server>PrintJobLimit为-1或300,1000,测试次数最多可延长至148次
 
重启IIS,测试网站,点击次数为235左右时又出错了(PrintJobLimit设置为-1,0,300,500结果一样)
3.2 系统TEMP目录赋予users操作的权限

3.3 使用BAT文件定时重启IIS

清空C:/Documents and Settings/username/ASPNET/Local Settings/Temp/ 下tmp文件

不是长久之计。

3.4  关闭和释放报表资源

private void Page_Unload(object sender, EventArgs e)
{
ReportDoc.Close();
ReportDoc.Dispose();
}

First, the problem is the AppPool, if you review the task manager you can see w3wp.exe with a high Mem Usage this is because you run many reports at the same time and keep alive for many time, this issue produce the error, because don't have more memory assigned to run more reports, the limit are 75. Review your settings in IIS Manager, indetify you application pool, in the Performace Options set "Shutdown worker proccess..." to 5 or something similar and "Limit the kernel request queue.." to 4000 or something similar. Open the report and see if w3wp.exe close or reduce Mem Usage in the time where you set.

4 总结

应急措施:重启IIS

永久措施:关闭和释放报表资源

5 参考文章

5.1 "The maximum report processing jobs limit configured by your system administrator has been reached."

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=71929&SiteID=1

5.2 Use the Close() Method to free up the report

http://msdn.microsoft.com/en-us/library/ms225490(VS.80).aspx

5.3 开启报表出错

http://blog.csdn.net/daisylh/archive/2006/12/12/1439312.aspx

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值