I have searched extensively and not found anything on how to do=
this=2E

The prolem is as follows=2E I have a console application that=
launches some command line utilities using the=
System=2EDiagnostic=2EProcess class=2E Basically I want to just kill=
any of these child processes if the parent/controlling app dies=2E=
I have tried everything suggested including things like=
implementing the IDisposable interface but nothing seems to work=
basically i need to terminate all child processes as soon as the=
parent dies=2E Any suggestions?
--------------------------------
From: Lloyd Gomes

-----------------------
Posted by a user from =2ENET 247 (http://www=2Edotnet247=2Ecom/)

<Id>qrRvd3FfvkGiESKUyPS9OQ=3D=3D</Id>

Re: Shutting down child processes started using System.Diagnostic.Process by Alvin

Alvin
Mon Mar 07 21:55:55 CST 2005

You should maintain a reference to the invokded process and store it
somewhere - static variable maybe (yuck, that is so wrong) - but then you
can use a catch handler to access the reference and kill the process when
the application domain unloads. That is, assuming you have put code in the
unload event for the application domain. makes sense?

--
Regards,
Alvin Bruney

[Shameless Author Plug]
The Microsoft Office Web Components Black Book with .NET
available at www.lulu.com/owc
------------------------------------------------------------

"Lloyd Gomes via .NET 247" <anonymous@dotnet247.com> wrote in message
news:ujGTI42IFHA.3064@TK2MSFTNGP12.phx.gbl...
I have searched extensively and not found anything on how to do this.

The prolem is as follows. I have a console application that launches some
command line utilities using the System.Diagnostic.Process class. Basically
I want to just kill any of these child processes if the parent/controlling
app dies. I have tried everything suggested including things like
implementing the IDisposable interface but nothing seems to work basically i
need to terminate all child processes as soon as the parent dies. Any
suggestions?
--------------------------------
From: Lloyd Gomes

-----------------------
Posted by a user from .NET 247 (http://www.dotnet247.com/)

<Id>qrRvd3FfvkGiESKUyPS9OQ==</Id>