Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to prevent the MS Excel error dialog by errorhandling ?
I am building a MS Excel application which uses a VB ActiveX dll. In order
to handle unexpected errors, I've added 'on error goto errorhandler' both in the routines in the dll as well as in the subroutines in the Excel VBE. However in some unpredictable cases MS Excel fires an error by which the following Excel dialog appears : An error has appeared in MS Excel and has to be closed. We offer our apologizes for this unconvenience....and asks for sending the report to MS. After closing this form, Excel is also closed and the whole thing has to be started again. Since the problem doesn't occur all the time even after performing the same steps this must be due to Excel and I am not able to solve this. I was wondering whether there is a kind of errorhandling or setting other than I've described above which can trap the Excel error so that Excel would not be closed automatically. Oscar |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to prevent the MS Excel error dialog by errorhandling ?
Hi Oscar,
No, this is an unhandled application error, and you can't trap it. You'll have to figure out what bit of code is causing Excel to crash and work around it. Sometimes adding a few DoEvents statements to the offending bit of code will take care of issues like this. If you look up the actual error code on the MS site, you may find bug-related information. -- Regards, Jake Marx MS MVP - Excel www.longhead.com [please keep replies in the newsgroup - email address unmonitored] Oscar wrote: I am building a MS Excel application which uses a VB ActiveX dll. In order to handle unexpected errors, I've added 'on error goto errorhandler' both in the routines in the dll as well as in the subroutines in the Excel VBE. However in some unpredictable cases MS Excel fires an error by which the following Excel dialog appears : An error has appeared in MS Excel and has to be closed. We offer our apologizes for this unconvenience....and asks for sending the report to MS. After closing this form, Excel is also closed and the whole thing has to be started again. Since the problem doesn't occur all the time even after performing the same steps this must be due to Excel and I am not able to solve this. I was wondering whether there is a kind of errorhandling or setting other than I've described above which can trap the Excel error so that Excel would not be closed automatically. Oscar |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
prevent div/0 error | Excel Worksheet Functions | |||
Error dialog box meaning and how to find error | Excel Worksheet Functions | |||
Excel Spreadsheet Not Saved Dialog Error | Excel Discussion (Misc queries) | |||
Common Dialog Error | Excel Programming | |||
Prevent dialog - Prevents Sending Excel File From Outlook | Excel Programming |