Jump to content

Recommended Posts

Posted

I have a simple do loop and within the loop I need it to

run commands one after the other. I have the loop set now to

3 and I expect each runwait to be called one after the other.

I am however seing that each runwait is called 3 times then

the next one. What am I missing here.

; Set the counter

$count = 1

; Execute the loop "until" the counter is greater than 5

Do

; Print the count

;MsgBox(0, "COUNT NUMBER", "Count is:" & $count, 3)

RunWait("E:\share-main\Autoit\RGDK\reboot.au3.exe", "", @SW_MINIMIZE)

RunWait("E:\share-main\Autoit\RGDK\telstar-getuptime.au3.exe", "", @SW_MINIMIZE)

RunWait("E:\share-main\Autoit\RGDK\file-check.au3.exe", "", @SW_MINIMIZE)

; Increase the count by one

$count = $count + 1

Until $count > 3

Posted

...I am however seing that each runwait is called 3 times then the next one...

I do not see that behavior with this simple test script:
For $i = 1 To 3
    RunWait("notepad")
    RunWait("calc")
Next
Do you?

(Manually kill each window.)

[size="1"][font="Arial"].[u].[/u][/font][/size]

Posted

I do not see that behavior with this simple test script:

For $i = 1 To 3
    RunWait("notepad")
    RunWait("calc")
Next
Do you?

(Manually kill each window.)

Well thanks for the direction, but still have the same problem, my three scripts do close all windows and then exits.

Posted

Well thanks for the direction, but still have the same problem, my three scripts do close all windows and then exits.

Then I take it that notepad and calc behaved as expected for you, but not your script that calls 3 other scripts via RunWait? Sorry, I don't know why that would be - perhaps you could post some small scripts that would allow us to reproduce the problem.

[size="1"][font="Arial"].[u].[/u][/font][/size]

Posted

Then I take it that notepad and calc behaved as expected for you, but not your script that calls 3 other scripts via RunWait? Sorry, I don't know why that would be - perhaps you could post some small scripts that would allow us to reproduce the problem.

Thanks much anyway

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
  • Recently Browsing   0 members

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