myExcel = New Microsoft.Office.Interop.Excel.Application
That seems to work fine. I then go on to try to set the
InitialFileName property of the FileDialog using
myExcel.FileDialog(msoFileDialogSaveAs).InitialFileName = "C:
\Book1.xls"
The rest of my code seems to work fine, but when I run this line of
code, I get a run time error that says:
Unhandled exception of type
"System.Runtime.InteropServices.COMException" occured in
Microsoft.VisualBasic.dll
Additional information: The server threw an exception. (Exception
from HRESULT: 0x80010105 (RPC_E_SERVERFAULT))
I'm not sure what I'm doing wrong. Any ideas...
MattM
Wrong newsgroup - this is for VB Classic - VB6 and earlier. Look for
newsgroups with dotnet in their name - try
microsoft.public.dotnet.languages.vb
--
Michael Cole