首页 > 其他分享 >An error has occurred during report processing

An error has occurred during report processing

时间:2023-11-16 14:04:08浏览次数:50  
标签:WebForms String processing ex InnerException report during Microsoft inner

ex.Message: An error has occurred during report processing.

ex.Source: Microsoft.ReportViewer.WebForms ex.StackTrace:  

at  Microsoft.Reporting.WebForms.LocalReport.InternalRender(String format, Boolean allowInternalRenderers, String deviceInfo, CreateAndRegisterStream createStreamCallback, Warning[]& warnings)

at  Microsoft.Reporting.WebForms.LocalReport.InternalRender(String format, Boolean allowInternalRenderers, String deviceInfo, String& mimeType, String& encoding, String& fileNameExtension, String[]& streams, Warning[]& warnings)

at  Microsoft.Reporting.WebForms.LocalReport.Render(String format, String deviceInfo, String& mimeType, String& encoding, String& fileNameExtension, String[]& streams, Warning[]& warnings)

 

http://social.msdn.microsoft.com/forums/en-US/vsreportcontrols/thread/5d58c5bf-374d-488d-bc8e-43cd99b0be83/

I was finally able to find the "inner exception" info. Here's what i added:

Try

report.Render("Image", deviceInfo, AddressOf CreateStream, warnings)
Catch e As System.Exception
   Dim inner As Exception = e.InnerException
   While Not (inner Is Nothing)
      MsgBox(inner.Message)
      inner = inner.InnerException
   End While
End Try
 
catch (Exception ex)   
        {    
            Exception inner = ex.InnerException;    
            string messages = "";    
            while (inner != null)    
            {    
                messages += "; " + inner.Message;    
                inner = inner.InnerException;    
            }              MsgBox(messages );
        }

The second line above is from the code posted about printing without print preview so the try-catch block goes around it. I was finally able to determine the error occurring which was a datasource had not been supplied (which was but the name didn't exactly match). Anyway, the report successfully printed this afternoon without a print preview!!!



标签:WebForms,String,processing,ex,InnerException,report,during,Microsoft,inner
From: https://blog.51cto.com/emanlee/8418850

相关文章

  • Only export to PDF format from ReportViewer add-in
    Hiall,"OnlyexporttoPDFformatfromReportVieweradd-in"...Isthispossible?Rightnowthereportviewerhastwooptionsofexportingthecurrentreport-ExcelandPDF...IsitpossibletohavePDFastheonlyoption.Idon'twantmyclient......
  • Can Report (rdlc) Table or Matrix Column Width Be Set at Runtime?
     UsinganrdlcreportinReportViewer,Ineedtocreateatableormatrixwherethenumberofcolumnsandthekindsofdatadisplayedinthecolumnschangeswitheachreport. Forexample,inonereport,thesecondcolumnmayholdpriceinformation. Ina......
  • 界面组件DevExpress Reporting v23.1亮点 - 全新升级报表查看器
    DevExpressReporting是.NETFramework下功能完善的报表平台,它附带了易于使用的VisualStudio报表设计器和丰富的报表控件集,包括数据透视表、图表,因此您可以构建无与伦比、信息清晰的报表界面组件DevExpressReportingv23.1已经发布一段时间了,新版本在报表查看器中拥有新的缩放......
  • FastReport打印DataBand分列:DataBand.Columns.Count
    FastReport打印DataBand分列,DataBand.Columns.Count。看图,转载请注明海宏软件:下面的图片:diffImg、pltImg、rbcImg实际上是三行记录,横着打印了。 C#下载网页文件并存入DataTable的DataRow的DataColumn字段里:if(web==null)web=newWebClient();row["oImg"]=web.Down......
  • ReportViewer (RDLC) 中的换行符是什么
     报表换行 1ReportViewer(RDLC)中的换行符是什么:chr(13)&chr(10) , 或者 & vbcrlf &示例:=Fields!FirstLine.Value&chr(13)&chr(10)&Fields!SecondLine.Value 2ReportViewer(RDLC)中改变文字方向:水平,纵向(垂直)WritingMode:tb-rl 纵向(垂直)WritingMod......
  • Adding custom code to Local Reports in Visual Studio.NET 2005 (Problems & Soluti
    AddingcustomcodetoLocalReportsinVisualStudio.NET2005(Problems&Solutions)IfyouareoneofthepeoplewhousedandenjoyedSQLServerReportingServices(SSRS)inSQL2000andyouwantedtouseitinyourwindows/webapplicationswithou......
  • Catch ReportViewer Exception
    Problem: IwouldliketoknowhowIcancatcherrorsthatshowuponmyreportviewerwebservercontrolwhenforinstancethereisaparameterwhosevaluewasnotset.Solution:YoucanyoutheReportErrormethodoftheReportViewercontrol.Ithasan......
  • Adding empty space into SQL Server Reporting Services
    REF:http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1400080&SiteID=1(1)Ratherthaninsertingspaces,canyouadjustthepaddingpropertyonthetextbox?Ifyougoalistohavethefieldindented,thatshouldwork.(2)Anyreasonyoucouldn'......
  • How to grant permissions to a custom assembly that is referenced in a report in
    Ref:http://support.microsoft.com/kb/842419/en-us HowtograntpermissionstoacustomassemblythatisreferencedinareportinReportingServicesViewproductsthatthisarticleappliesto.ArticleID:842419LastReview:April3,2007Revision:2.1OnThisPa......
  • How to add an image on reportViewer (rdlc)
    OpenthereportintheDesigner.IntheToolBox,select/expandthe"ReportItems"section.Dragan"Image"field/controlontothereport.ClickontheimageandpressF4,thepropertieswindow popsup,underthegroupdatayou'llf......