0
votes

My app (winforms .net 2.0 / vs2008) works fine on my dev machine but on one of test machines i'm getting this exception. Has anybody encountered something similar?

************** Exception Text **************
Microsoft.Reporting.WinForms.LocalProcessingException: An error occurred during local report processing. ---> Microsoft.Reporting.DefinitionInvalidException: The definition of the report 'Main Report' is invalid. ---> Microsoft.ReportingServices.Diagnostics.Utilities.ServerConfigurationErrorException: The report server has encountered a configuration error. See the report server log files for more information.
   at Microsoft.ReportingServices.Diagnostics.DataProtectionLocal.ProtectData(Byte[] data, Int32 dwFlags)
   at Microsoft.ReportingServices.DataExtensions.DataSourceInfo..ctor(String originalName, String extension, String connectionString, Boolean originalConnectStringExpressionBased, Boolean integratedSecurity, String prompt)
   at Microsoft.ReportingServices.ReportProcessing.ReportPublishing.ReadDataSource(DataSourceNameValidator dataSourceNames, PublishingContext context)
   at Microsoft.ReportingServices.ReportProcessing.ReportPublishing.ReadDataSources(PublishingContext context)
   at Microsoft.ReportingServices.ReportProcessing.ReportPublishing.ReadReport()
   at Microsoft.ReportingServices.ReportProcessing.ReportPublishing.Phase1(CatalogItemContext reportContext, Byte[] definition, CreateReportChunk createChunkCallback, CheckSharedDataSource checkDataSourceCallback, String& description, String& language, DataSourceInfoCollection& dataSources, UserLocationFlags& userReferenceLocation, Boolean& hasExternalImages, Boolean& hasHyperlinks)
   at Microsoft.ReportingServices.ReportProcessing.ReportPublishing.CreateIntermediateFormat(CatalogItemContext reportContext, Byte[] definition, CreateReportChunk createChunkCallback, CheckSharedDataSource checkDataSourceCallback, PublishingErrorContext errorContext, AppDomain compilationTempAppDomain, Boolean generateExpressionHostWithRefusedPermissions, String& description, String& language, ParameterInfoCollection& parameters, DataSourceInfoCollection& dataSources, UserLocationFlags& userReferenceLocation, ArrayList& dataSetsName, Boolean& hasExternalImages, Boolean& hasHyperlinks)
   at Microsoft.ReportingServices.ReportProcessing.ReportProcessing.CompileReport(CatalogItemContext reportContext, Byte[] reportDefinition, CreateReportChunk createChunkCallback, CheckSharedDataSource checkDataSourceCallback, PublishingErrorContext errorContext, AppDomain compilationTempAppDomain, Boolean generateExpressionHostWithRefusedPermissions, String& reportDescription, String& reportLanguage, ParameterInfoCollection& parameters, DataSourceInfoCollection& dataSources, UserLocationFlags& userReferenceLocation, ArrayList& dataSetsName, Boolean& hasExternalImages, Boolean& hasHyperlinks)
   at Microsoft.ReportingServices.ReportProcessing.ReportProcessing.CreateIntermediateFormat(CatalogItemContext reportContext, Byte[] reportDefinition, CreateReportChunk createChunkCallback, CheckSharedDataSource checkDataSourceCallback, AppDomain compilationTempAppDomain, Boolean generateExpressionHostWithRefusedPermissions)
   at Microsoft.Reporting.ReportCompiler.CompileReport(CatalogItemContext context, Byte[] reportDefinition, Boolean generateExpressionHostWithRefusedPermissions, ReportSnapshotBase& snapshot)
   --- End of inner exception stack trace ---
   at Microsoft.Reporting.ReportCompiler.CompileReport(CatalogItemContext context, Byte[] reportDefinition, Boolean generateExpressionHostWithRefusedPermissions, ReportSnapshotBase& snapshot)
   at Microsoft.Reporting.StandalonePreviewStore.StoredReport.CompileReport()
   at Microsoft.Reporting.StandalonePreviewStore.StoredReport.get_Snapshot()
   at Microsoft.Reporting.StandalonePreviewStore.GetCompiledReport(CatalogItemContext context, Boolean rebuild, ReportSnapshotBase& snapshot)
   at Microsoft.Reporting.LocalService.GetCompiledReport(CatalogItemContext itemContext, Boolean rebuild, ReportSnapshotBase& snapshot)
   at Microsoft.Reporting.LocalService.CompileReport(CatalogItemContext itemContext, Boolean rebuild)
   at Microsoft.Reporting.WinForms.LocalReport.CompileReport()
   --- End of inner exception stack trace ---
   at Microsoft.Reporting.WinForms.LocalReport.CompileReport()
   at Microsoft.Reporting.WinForms.LocalReport.SetParameters(IEnumerable`1 parameters)
   at XXX.Helpers.Report.PrintFavs(List`1 list, String header, String filename) in C:\Data\projects\workdir_cpv\Src\Classes\Helpers\Report.cs:line 112
3

3 Answers

0
votes

I had something similar once. You might want to make sure the test machine has the ReportViewer dll installed in the GAC. Microsoft has created an installer to make this easier.

Question: Are you using Reporting Services in local mode with a report viewer control inside winforms?

0
votes

The vs2008 designer for reports and report viewer are not backwards compatible with 2.0. In the same way you cannot design 2005 reports with vs2008 - that may be your issue.

0
votes

My installer copies all required dlls

Microsoft.ReportViewer.Common.dll

Microsoft.ReportViewer.ProcessingObjectModel.dll

Microsoft.ReportViewer.Winforms.dll

to ProgramFiles/myAppname folder.

It works perfectly on Vista/XP but the issue is at Win98. I'll try to install these dll's at GAC, maybe that's a problem. I'm trying to avoid running extra installers inside my installer.

@keithwarren7:

if that's true, then it's really stupid. do you know any simple & free report engine for .net 2.0?