Hello Rob,

Thanks for the reply. Please see my comment inline.

>> I'm using the Skyp4COM object in a delphi app. Sometimes the
>> application (not the COM object itself) shows error message dialog
>> boxes from the COM object. There is an error event from the COM
>> object and I'm catching that, but this doesn't help.

> Are you sure you're catching the right exception type?

As a matter of fact, I'm not catching any exceptions. I'm only
handling the error event. When the exceptions happen, the error
events are also fired but handling them doesn't prevent the error
messages. I think it's a good idea to put some try-catch blocks
around calls to the COM object. However, I suppose this does not
help if the COM object is doing something in its own threads and
an exception happens in those threads? Is there a good way to
catch those exceptions?

>> The app still
>> shows these error messages. Skype4COM developers confirm that
>> the COM object is not showing any error boxes. I checked all my code
>> (only a few files) and there is no ShowMessage or MessageBox. The
>> error message title is the file name of the application. I wonder
>> if this is some default behavior of COM objects, and if there
>> is a generic way to prevent Delphi apps to show COM errors?

> While the message box is showing, press the "pause" button in the IDE.
> Then bring up the call stack, and you'll see exactly who's displaying the
> dialog box.

The thing is, during debugging, the error is difficult to reproduce.
It only happens when traffic is high, with many concurrent users.

> A likely candidate is Delphi's built-in exception handler. It gets invoked
> whenever an exception goes unhandled while a control's event handler is
> active.

Is there a generic way to replace the exception handler and catch
those uncaught exceptions? I suppose there must be, because that's
how tools like madExcept work?

I'll start with putting in some try catch blocks first. Thanks!

-- 
Best regards,
Jack

_______________________________________________
Delphi mailing list -> [email protected]
http://lists.elists.org/cgi-bin/mailman/listinfo/delphi

Reply via email to