Jump to content
Sign in to follow this  
JohnMC

Stop 3rd Party process upon Process Close/Die

Recommended Posts

JohnMC

Im developing a portable web server for an opensource project call Simple Invoices, im using autoit to start and manage: a UI w/ embedded ie, mysql server, apache web server, etc. Ive run into an issue were if a user force closes my autoit script or if it crashes, all the sub processes remain running.

My question is; what is the best way to handle this? my only idea has been to create a simple helper process, but this seems messy and still with a chance of issues not to mention the idea of portable is a small footprint.

my dream would be to discover some sort of dll call or a special way of executing a process that says x child cant continue to run without y parent.

thanks for any help!

Share this post


Link to post
Share on other sites
sleepydvdr

I don't think this would help in case of the program crashing, but OnAutoItExitRegister might be helpful with the user closing it.


#include <ByteMe.au3>

Share this post


Link to post
Share on other sites
JohnMC

I don't think this would help in case of the program crashing, but OnAutoItExitRegister might be helpful with the user closing it.

thanks, ya im using that for normal closes

the script shutdown process is complicated but i dont expect anything special to happen if my script dies, i just want the child processes (3rd party executables) to die with it, all my googleing keeps bringing me back to a helper process to monitor the situation and close everything when needed

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.