Dirk98 Posted September 23, 2007 Share Posted September 23, 2007 Guys ProcessClose() doesn't close all instances of the running process. How to close ALL INSTANCES of the same process? Thanks. Link to comment Share on other sites More sharing options...
Dirk98 Posted September 23, 2007 Author Share Posted September 23, 2007 ProcessWaitClose() helped. Don't know if it is the best method though. Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted September 23, 2007 Moderators Share Posted September 23, 2007 I gave you the answer to this in your other thread:http://www.autoitscript.com/forum/index.ph...st&p=407525 Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
Dirk98 Posted September 23, 2007 Author Share Posted September 23, 2007 (edited) I gave you the answer to this in your other thread:http://www.autoitscript.com/forum/index.ph...st&p=407525EDIT:Yes, SmokeOn, you're spot on, I'm very sorry!I'm still getting confused in this stuff easily.Many thanks. Edited September 23, 2007 by Dirk98 Link to comment Share on other sites More sharing options...
rasim Posted September 23, 2007 Share Posted September 23, 2007 While ProcessExists("notepad.exe") ProcessClose("notepad.exe") WEnd Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted September 23, 2007 Moderators Share Posted September 23, 2007 While ProcessExists("notepad.exe") ProcessClose("notepad.exe") WEndThis is a good example, but keep in mind you are continuously enuming the process list here, where as if you do it the way I have in the other example, you enum it once. Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
Dirk98 Posted September 23, 2007 Author Share Posted September 23, 2007 This is a good example, but keep in mind you are continuously enuming the process list here, where as if you do it the way I have in the other example, you enum it once.Do you mean it runs continuously until the script exits, right? Link to comment Share on other sites More sharing options...
Dirk98 Posted September 23, 2007 Author Share Posted September 23, 2007 Do you mean it runs continuously until the script exits, right?Will it work if the process I want to close is AutoIt.exe to avoid multiple instances of the same? Or there's some third way to achieve that?Many thanks. Link to comment Share on other sites More sharing options...
Generator Posted September 23, 2007 Share Posted September 23, 2007 #include<misc.au3> _Singleton("Myscript") Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now