Jump to content

help running more then 1 autoit


Guest belgarath
 Share

Recommended Posts

Guest belgarath

i have made a sweet script that does exactly what i want now i want to go all out and run 2-4 at the same time on the one desktop.

what im doing

i have a script that waits for pixels to change in the window and then responds with mouse clicks

i want to run 4 of these windows on my desktop sectioned off

how do i get this to run do i need 4 auto its' running would the mouse clash some place or can i do it with 1 script

i would rather 4 autoit scripts running 1 for each it would make it easier

but if all 4 tried to use the mouse im guessing there would be a problem

Link to comment
Share on other sites

Guest Py7|-|[]/\/

ProcessWait

--------------------------------------------------------------------------------

Pauses script execution until a given process exists.

ProcessWait ( "process" [, timeout])

Parameters

process The name of the process to check.

timeout [optional] Specifies how long to wait (default is to wait indefinitely).

Return Value

Success: Returns 1.

Failure: Returns 0 if the wait timed out.

Remarks

Process names are executables without the full path, e.g., "notepad.exe" or "winword.exe"

In order to work under Windows NT 4.0, ProcessWait requires the file PSAPI.DLL (included in the AutoIt installation directory).

The process is polled approximately every 250 milliseconds.

This function is the only process function not to accept a PID. Because PIDs are allocated randomly, waiting for a particular PID to exist doesn't make sense.

Related

ProcessClose, ProcessExists, ProcessWaitClose, RunWait, WinWait, WinWaitActive

Example

ProcessWait("notepad.exe")

This might be of some help. If an AutoIt script can detect another AutoIt script then you are in luck! Edited by Py7|-|[]/\/
Link to comment
Share on other sites

Guest belgarath

thx heaps for the quick reply ill get on it right away

p.s. i love this proggie i script mirc stuff all the time this was a piece of cake to pick up great work guys/gals

Link to comment
Share on other sites

Guest Py7|-|[]/\/

Sure thing, good luck with getting it to work.

Read below, scriptkitty knows a lot more than I.

Edited by Py7|-|[]/\/
Link to comment
Share on other sites

I would sugest using Handles, get the unique handles of all 4 and have one script cycle checking each one. The difference in one script checking 4 windows, and 4 scripts all checking one windowon the same computer will be about the same, but you would be able to predict mouse movement and make sure it doens't go haywire.

You could have autoIt rename each window to a different and unique name or something like window1, window2, window3, window4, however there are many things that can change window titles, so I would suggest handles.

It will take a bit more writing for 4 checks, but not all that rough, and you don't have to worry about which autoit to turn off when things go wrong.

AutoIt3, the MACGYVER Pocket Knife for computers.

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...