G
Guest
Hello -
I'm opening/saving an Excel workbook from ASP.Net. When I try to save the
workbook I get the error:
System.Runtime.InteropServices.COMException: The remote procedure call failed.
Code:
Dim oExcel As New Excel.Application()
Dim oBooks As Excel.Workbooks
Dim oBook As Excel.Workbook
oExcel.Visible = True
oExcel.DisplayAlerts = False
'Start a new workbook
oBooks = oExcel.Workbooks
oBooks.Open("c:\test.xls", 0)
oBook = oBooks.Item("test.xls")
:
:
oBook.SaveAs(sTemplate) '**** Occurs Here *****
oBook.Close()
Suggestions/workarounds?
Thanks, Mark
I'm opening/saving an Excel workbook from ASP.Net. When I try to save the
workbook I get the error:
System.Runtime.InteropServices.COMException: The remote procedure call failed.
Code:
Dim oExcel As New Excel.Application()
Dim oBooks As Excel.Workbooks
Dim oBook As Excel.Workbook
oExcel.Visible = True
oExcel.DisplayAlerts = False
'Start a new workbook
oBooks = oExcel.Workbooks
oBooks.Open("c:\test.xls", 0)
oBook = oBooks.Item("test.xls")
:
:
oBook.SaveAs(sTemplate) '**** Occurs Here *****
oBook.Close()
Suggestions/workarounds?
Thanks, Mark