AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

trigger macro when program is closed

 
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
tommyrot



Joined: 02 Aug 2006
Posts: 8

PostPosted: Tue Oct 24, 2006 2:36 am    Post subject: trigger macro when program is closed Reply with quote

Here's another tricky one!

I want to be able to trigger a macro that restarts the PC whenever a nominated program is ended in the task manager... any thoughts?
Back to top
View user's profile Send private message
AiKscroll



Joined: 06 Jun 2005
Posts: 179
Location: Northern Virginia

PostPosted: Tue Oct 24, 2006 2:45 am    Post subject: Reply with quote

Check out Windows Messages
_________________
_AiK
Back to top
View user's profile Send private message AIM Address
.AHK



Joined: 26 Apr 2006
Posts: 662
Location: USA

PostPosted: Tue Oct 24, 2006 2:56 am    Post subject: Reply with quote

Code:

Run notepad.exe
Loop {
Sleep 100
Process Exist, notepad.exe
If ErrorLevel = 0
{
MsgBox Notepad.exe closed.
Break
}
}
Return
Back to top
View user's profile Send private message Visit poster's website AIM Address
Display posts from previous:   
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group