cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

System.Runtime.InteropServices.COMException: The document has not been opened.

Former Member
0 Likes
1,094

Hello,

I have a couple of .net apps running on a Windows Server 2012 R2. The apps were developed in Visual Studio 2015 and include Crystal Reports, reports. They have been running for years but now when users try to open the reports they get the error shown in the screen shot below.

Here is a snippet of the code that creates a report.

ReportName = "Category"
MakeCrParameter(txtStartDate.Text, "@StartDate", crpt)
MakeCrParameter(txtEndDate.Text, "@EndDate", crpt)
Dim FileName As String = ReportName & " " & Now.Month & "-" & Now.Day & "-" & Now.Year & "-" & Now.Second & ".pdf"
Dim dfdo As New DiskFileDestinationOptions() dfdo.
DiskFileName = "C:\WebApps\EslCalls\Reports\" & FileName
With crpt
.ExportOptions.ExportDestinationType = ExportDestinationType.DiskFile
.ExportOptions.ExportFormatType = ExportFormatType.PortableDocFormat
.ExportOptions.DestinationOptions = dfdo .Export()
.Close()
.Dispose()
End With

I tried reinstalling the SAP Crystal Reports runtime engine for.NET Framework (64-bit) version 13.0.10.1385 on the server but that didn't remedy the situation.

Any suggestions would be greatly appreciated.

View Entire Topic
0 Likes

Hi Les,

I changed the Tag to CR for VS.

I doubt it's your code or CR runtime, likely cause is a recent MS Windows update is now blocking access to the resources.

SP 10 is very old, you can get the latest from here:

https://wiki.scn.sap.com/wiki/display/BOBJ/Crystal+Reports%2C+Developer+for+Visual+Studio+Downloads

It now uses 4.0 framework minimum, read all of the info for SP 21. we changed the C++ builder to VC 2015 so it no use the MS VC 2015 C++ runtime and other newer dependencies since MS no longer supports those old one.

It will require you to rebuild your app with the updated Assemblies as well as deploying the MSI redist package on your WEB server.