Sign in to follow this  
Followers 0
Stunt

Do loop, or a for loop

3 posts in this topic

Hi Guys,

Cant get this to run through all the steps, any ideas. I have tried with a Do and a for but no luck.

Do

$n=0

ControlSend($JASWind, "", "", "{TAB}")

Sleep(5000)

If $n = 5 Then

Sleep(5000)

ControlSend($JASWind, "", "", "\\shjdedp01\B7334\PY7334\PACKAGE\AUTODEPLOY\work\GeneratorList.txt")

Else If $n = 12 Then

Sleep(5000)

ControlSend($JASWind, "", "", "ENTER")

Else If $n = 13 Then

Sleep(5000)

ControlSend($JASWind, "", "", "{ALTDOWN}f{ALTUP}b{ENTER}")

EndIf

$n=$n+1

Until $n=13

Share this post


Link to post
Share on other sites



Try:

$n = 0

Do

    ControlSend($JASWind, "", "", "{TAB}")
    Sleep(5000)


    If $n = 5 Then
        Sleep(5000)
        ControlSend($JASWind, "", "", "\\shjdedp01\B7334\PY7334\PACKAGE\AUTODEPLOY\work\GeneratorList.txt")
    Else If $n = 12 Then
        Sleep(5000)
        ControlSend($JASWind, "", "", "ENTER")
    Else If $n = 13 Then
        Sleep(5000)
        ControlSend($JASWind, "", "", "{ALTDOWN}f{ALTUP}b{ENTER}")
    EndIf
    $n = $n + 1
Until $n = 13

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Share this post


Link to post
Share on other sites

Try:

$n = 0

Do

    ControlSend($JASWind, "", "", "{TAB}")
    Sleep(5000)
    If $n = 5 Then
        Sleep(5000)
        ControlSend($JASWind, "", "", "\\shjdedp01\B7334\PY7334\PACKAGE\AUTODEPLOY\work\GeneratorList.txt")
    Else If $n = 12 Then
        Sleep(5000)
        ControlSend($JASWind, "", "", "ENTER")
    Else If $n = 13 Then
        Sleep(5000)
        ControlSend($JASWind, "", "", "{ALTDOWN}f{ALTUP}b{ENTER}")
    EndIf
    $n = $n + 1
Until $n = 13

stupid stupid stunt :), thanks dude.

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  
Followers 0