WoodGrain Posted October 20, 2016 Posted October 20, 2016 Hi All, I run multiple AutoIT scripts concurrently, is there a way of distinguishing between them? When I look under Details in task manager I just see a bunch of "AutoIt3.exe" processes. Under the processes tab I again just see a bunch of "AutoIt v3 Script" or "AutoIt v3 Script (32 bit)" applications. When I hover my mouse over the tray icon I can see the tooltip "AutoIt - Current Time.au3" but am not sure how to reference this. For example if I run a script called "Current Time.au3", how can I determine from another au3 script if this "Current Time.au3" script is running and grab it's handle (using WinGetHandle() or similar)? Following from that l'd even like to pause/resume the script, if that's possible.. Cheers!
Anoop Posted October 20, 2016 Posted October 20, 2016 JFYI - If you convert it to exe and run, you can see the executable file name in task manager.
WoodGrain Posted October 20, 2016 Author Posted October 20, 2016 Thanks for the great idea Anoop, will definitely keep it in mind. I'd like to find some code for the au3 files in this particular scenario, and I'd like to figure out how to pause/resume the script as well.
l3ill Posted October 20, 2016 Posted October 20, 2016 Have a look at the function called _Singleton That should help with your scenario My Contributions... SnippetBrowser NewSciTE PathFinder Text File Manipulation FTP Connection Tester / INI File - Read, Write, Save & Load Example
TheSaint Posted October 20, 2016 Posted October 20, 2016 One way would be to launch them all from the same master program, and get a PID for each off the Run command. And there are various other ways, involving writing to a checking file or Registry entry etc. Xandy 1 Make sure brain is in gear before opening mouth! Remember, what is not said, can be just as important as what is said. Spoiler What is the Secret Key? Life is like a Donut If I put effort into communication, I expect you to read properly & fully, or just not comment. Ignoring those who try to divert conversation with irrelevancies. If I'm intent on insulting you or being rude, I will be obvious, not ambiguous about it. I'm only big and bad, to those who have an over-active imagination. I may have the Artistic Liesense to disagree with you. TheSaint's Toolbox (be advised many downloads are not working due to ISP screwup with my storage)
WoodGrain Posted October 20, 2016 Author Posted October 20, 2016 Those are both helpful ideas, thanks guys I'll look into both
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