M
Michael E. Pouliot
My VB.NET application spins up a secondary GUI thread. This thread hosts a
Custom User Control (which owns the window handle) and some COM objects
which interact with a Third Party Application. When a method call to one of
the COM objects results in an error, the .NET Interop throws a
System.Runtime.InteropServices.COMException, as one would expect. However,
while generating this exception, both the main and secondary GUI threads are
halted. I can find no explanation for why the main thread should halt
during this time. The entire purpose of spinning up a secondary GUI thread
was to allow the primary GUI thread to stay active while COM related
processing was occurring. Does anyone know what is happening under the
covers of the COM Interop that would cause this? This pause (of about three
seconds) only occurs when the first COMException is thrown. Subsequent
exceptions do not cause the entire application to halt.
Thanks,
MP
Custom User Control (which owns the window handle) and some COM objects
which interact with a Third Party Application. When a method call to one of
the COM objects results in an error, the .NET Interop throws a
System.Runtime.InteropServices.COMException, as one would expect. However,
while generating this exception, both the main and secondary GUI threads are
halted. I can find no explanation for why the main thread should halt
during this time. The entire purpose of spinning up a secondary GUI thread
was to allow the primary GUI thread to stay active while COM related
processing was occurring. Does anyone know what is happening under the
covers of the COM Interop that would cause this? This pause (of about three
seconds) only occurs when the first COMException is thrown. Subsequent
exceptions do not cause the entire application to halt.
Thanks,
MP