on 07-22-2019 9:31 PM
I have a report that runs without any issue when preview in CR or Visual Studio. However, when runs with C# code which provides the parameter values, it threw "Missing parameter values" exception at the following line -
report.ExportToStream(CrystalDecisions.Shared.ExportFormatType.PortableDocFormat);
(where report is ReportDocument report)
The error I got is
'repInfo.StreamFile = report.ExportToStream(CrystalDecisions.Shared.ExportFormatType.PortableDocFormat)' threw an exception of type 'CrystalDecisions.CrystalReports.Engine.ParameterFieldCurrentValueException'
Data: {System.Collections.ListDictionaryInternal}
ErrorID: MissingParameterFieldCurrentValue
HResult: -2147215870
HelpLink: null
InnerException: {"Missing parameter values."}
Message: "Missing parameter values."
PromptEngineAvailable: false
Source: "CrystalDecisions.ReportAppServer.DataSetConversion"
StackTrace: " at CrystalDecisions.ReportAppServer.ConvertDotNetToErom.ThrowDotNetException(Exception e)\r\n at CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext)\r\n at CrystalDecisions.CrystalReports.Engine.FormatEngine.ExportToStream(ExportRequestContext reqContext)\r\n at CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToStream(ExportOptions options)\r\n at CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToStream(ExportFormatType formatType)"
TargetSite: {Boolean ThrowDotNetException(System.Exception)}
I'm pretty sure my code provided the needed values. I really appreciate if anyone can shed some lights on the problem.
Try running the report with out setting parameters to see if it prompts for them
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.