Jump to content

Need to improve my working code with PID specifics

Recommended Posts

Heres the code:

Run("C:\Program Files (x86)\nost begins\WoW.exe")
WinWait("World of Warcraft")
WinActivate("World of Warcraft")
WinClose("World of Warcraft")

What this does is open world of warcraft, type in acc / pw, logs in, and logs into my character, and starts my recording software with the home hotkey. Then closes it after 2 minutes (just for testing purposes. will be increased to 2 hours later / 7200000) 

What I want this to do instead is get the PID from the wow.exe when its ran by the script and wait for that specific PID window to activate, rather than waiting for any world of warcraft window, then I could later close that specific PID with winclose at end of this script. The reason I need PID specifics is because I will be having mutliple instances of World of Warcraft running and not using the PID will screw up this script. (multiboxing is allowed on the private server im using, don't worry! :P )

Additionally, I was wondering if I added exit or end to the end of this script if it will end the process in the task managers processes section. How can I ensure the script will end and remove from the processes after it does what it's intended to do? It seems to linger in my Task Managers processes after the script has been long completed. 

off topic: Oh, by the way, I'm new to the forums so I'm sorry to start off here with a question if that's rude! But, in truth I've been using the forum for help for a long time, just finally decided to create account and join the community. Im hoping to be a regular eventually, i'm loving autoit. 




Share this post

Link to post
Share on other sites


Welcome to the AutoIt forum.

Unfortunately you appear to have missed the Forum rules on your way in. Please read them now - particularly the bit about not discussing game interaction - and then you will understand why you will get no help and this thread will now be locked.

See you soon with a legitimate question I hope.



Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:


ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area


Share this post

Link to post
Share on other sites
This topic is now closed to further replies.

  • Create New...