TargetInvocationException - Export to PDF
Posted: Mon Jan 04, 2010 7:46 am
HI
DLL versions 2009.3.600.0
I get a TargetInvocationException from StiPdfExportService when I try to export a report to PDF.
When I select save as PDF in the viewer menu, I must select a certificate before I can continue. If I select one one certificate (self created), then I get the following exception.
System.Reflection.TargetInvocationException: An exception occurred during the operation, making the result invalid. Check InnerException for exception details. ---> System.Exception: DigitalSign error at step 3, code #80004005: Cannot find the certificate and private key for decryption
at Stimulsoft.Report.Export.StiPdfExportService.ThrowDigitalSignError(Int32 step, String message, Boolean showCode)
at Stimulsoft.Report.Export.StiPdfExportService.ThrowDigitalSignError(Int32 step)
at Stimulsoft.Report.Export.StiPdfExportService.CreateSignature(Byte[] buf, Boolean getCertificateFromCryptoUI, String certificateID, Boolean useLocalMachineCertificates)
at Stimulsoft.Report.Export.StiPdfExportService.ExportPdf(StiReport report, Stream stream, StiPdfExportSettings settings)
at Stimulsoft.Report.StiReport.ExportDocument(StiExportFormat exportFormat, StiExportService exportService, Stream stream, StiExportSettings settings)
at Stimulsoft.Report.Export.StiExportService.DoExport(StiExportInfo info)
at System.ComponentModel.BackgroundWorker.WorkerThreadStart(Object argument)
Why do I need to actually select a certificate to export to PDF?
DLL versions 2009.3.600.0
I get a TargetInvocationException from StiPdfExportService when I try to export a report to PDF.
When I select save as PDF in the viewer menu, I must select a certificate before I can continue. If I select one one certificate (self created), then I get the following exception.
System.Reflection.TargetInvocationException: An exception occurred during the operation, making the result invalid. Check InnerException for exception details. ---> System.Exception: DigitalSign error at step 3, code #80004005: Cannot find the certificate and private key for decryption
at Stimulsoft.Report.Export.StiPdfExportService.ThrowDigitalSignError(Int32 step, String message, Boolean showCode)
at Stimulsoft.Report.Export.StiPdfExportService.ThrowDigitalSignError(Int32 step)
at Stimulsoft.Report.Export.StiPdfExportService.CreateSignature(Byte[] buf, Boolean getCertificateFromCryptoUI, String certificateID, Boolean useLocalMachineCertificates)
at Stimulsoft.Report.Export.StiPdfExportService.ExportPdf(StiReport report, Stream stream, StiPdfExportSettings settings)
at Stimulsoft.Report.StiReport.ExportDocument(StiExportFormat exportFormat, StiExportService exportService, Stream stream, StiExportSettings settings)
at Stimulsoft.Report.Export.StiExportService.DoExport(StiExportInfo info)
at System.ComponentModel.BackgroundWorker.WorkerThreadStart(Object argument)
Why do I need to actually select a certificate to export to PDF?