I have created a form and a button in Visual Studio that will call and open Excel. In addition it also run the macro Auto_Open (which resides in Excel) using the Run command (Run("Auto_Open"). The Auto_Open macro calls a form within Excel and allows the user to Exit Excel without going to the normal File->Exit menu in Excel. When I click on the Exit button on the Excel form it gives me the following error:

Exception from HRESULT: 0x800A9C68

The error points back to my VB code that executes the Run command.

I appreciate any help you can give.



Re: VB Error when running Auto_Open macro in Excel

Spidermans_DarkSide - MSP, VSIP


Are you using VB.Net or VB6 or earlier

Which version of Visual Studio do you have

The VB in EXCEL is known as VBA or Visual Basic for Applications.





This forum is for VB.Net questions only, sorry.

Please see.>> PostID=551512&SiteID=1

Try the MAIN VBA forum please.>> ForumID=74&SiteID=1

or this one.>>>> S=B20000