Subject Re: Exiting gracefully from lost connection error (335544721)
Author almfgingras
--- In, "Terry kahler" <terry@a...>
> Maybe something not so gentle :)
> Try replacing Application.Terminate with ExitProcess(0)
> Terry

I guess I should learn more about the Windows API but yes, this
works. Thank you Terry.

I am just not sure whether all resources are freed properly when
using ExitProcess(0) but my guess is that they may not be freed
properly either when I use application.Terminate and get the 'Send
message to Microsoft' prompt.

The lost connection situation being an exception that occurs in +/-
rare occasions, I am quite happy to live with the ExitProcess(0) in
this situation.

Many thanks again to all for your help in finding a solution for
this matter.