Jump to content
Sign in to follow this  
tiger223

Winwait Commandline Help

Recommended Posts

tiger223

if $CmdLine[0] > 0 then

Run("D:\uptime.exe ip:" & $CmdLine[1] & " /cmd", "", @SW_SHOW)

WinWait("Test - '& $CmdLine[1] &'")

sleep(2900)

ControlSend("Test - '& $CmdLine[1] &'","","","-n{enter}")

endif

The window which is activated is Test - userinput

For some reason I can't get it to work. Any ideas? Thanks.

Share this post


Link to post
Share on other sites
scriptkitty

You used single and double quotes, use the same to start and end.

if $CmdLine[0] > 0 then
Run("D:\uptime.exe ip:" & $CmdLine[1] & " /cmd", "", @SW_SHOW)
WinWait("Test - " & $CmdLine[1])
sleep(2900)
ControlSend("Test - "& $CmdLine[1],"","","-n{enter}")
endif

AutoIt3, the MACGYVER Pocket Knife for computers.

Share this post


Link to post
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
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.