Hi Shawn,
First, you don't want an exception to shut the application down. What you
want is for an exception *handler* to shut the application down. The
difference is that the handler can shut it down gracefully. Therefore, you
can use an event in either thread that is raised when an exception occurs,
and subscribe to the event in the other thread.
--
HTH,
Kevin Spencer
Microsoft MVP
Professional Numbskull
Show me your certification without works,
and I'll show my certification
*by* my works.
"Shawn Meyer" <me@me.com> wrote in message
news:eN**************@tk2msftngp13.phx.gbl...
Hello,
I have a windows service. When the onstart fires, my app creates two
threads. The first is a processing thread and the second is a watcher
that
makes sure the everything is ok with the first thread. When a problem is
detected the second (watcher) thread stops the processing thread and then
throws an exception. This exception does not stop the service like I
would
think.
My question is, what is the best way for the watcher thread to shut the
service down.
Thanks,
Shawn