Jump to content

Can't Get My Script To Stop


Recommended Posts

Guest lifefadedmemory@hotmail.com
Posted

I wrote a program that just keeps clicking on different windows. I have it in repeat mode the script is as follow

Sleep, 10000

Repeat, 10000

LeftClick, x, y

LeftClick, x, y

LeftClick, x, y

LeftClick, x, y

EndRepeat

I took out the coorinates just. How can i get this to stop on command. I Try to run it all night but if I run it too long and I wake up I can't stop the program and must restart my computer. Is their a way to place a keycommand in their to shut down the program? Is their another way? Any information anyone could provide would be most helpful. Thanks in advance.

~Andrew

  • 4 weeks later...
Posted

What about to use a desktop shortcut (with an assigned shortcut key), to run a batch, which creates a stop file :whistle: ?

Stop.bat

Time /T > C:\\Stop.not

Sleep, 10000

Repeat, 10000

LeftClick, x, y

LeftClick, x, y

LeftClick, x, y

LeftClick, x, y

IfExist, C:\\Stop.not, Goto, Stop

EndRepeat

Stop:

Run, %COMSPEC% /C del C:\\Stop.not, , Hide

Exit

Posted

Start:

Sleep, 10000

Repeat, 10000

LeftClick, x, y

LeftClick, x, y

LeftClick, x, y

LeftClick, x, y

IfExist, C:\\Stop.not, Goto, Stop

EndRepeat

Stop:

Sleep, 1000

IfExist, C:\\Stop.not, Goto, Stop

Goto, Start

Delete the file Stop.not and the script will loop back

Posted

Or, with the help of the pstools you make a hot key commanded script that fires a

pskill autoit

a little brutal, but it should work...

:whistle: Yeah, I know the Beastmaster idea is better

Guest rathore
Posted

how about pausing the process? (i've a command line utility that can pause any process, and can resume it with /r parameter)

i guess only nt based OS support process pausing!

  • Recently Browsing   0 members

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