Jump to content

Wait for progressbar to complete then continue


Recommended Posts

I want to automate a cleaning program, so far i've managed to figure out some things but i got stuck trying to wait for a progressbar to complete.

I will try to explain with a picture (See attachment)

What i want to do is let the script wait for the Progressbar to complete then

Sleep (100) and continue with the rest of the script...

Here's my script (The BOLD section below is were i want to put the code)

;Opstarten Applicatie

Run("C:\Program Files\CCleaner\ccleaner.exe")

WinWaitActive("CCleaner")

; Begin opschonen sectie Windows

ControlFocus ( "CCleaner", "Opschonen", 3 )

ControlClick ( "CCleaner", "Opschonen", 3 , "left" , 1 )

Sleep (2000) ; wacht 2 seconden

; Begin opschonen sectie Applicaties

Send ( "{TAB}")

Sleep (100)

Send ( "{TAB}")

Sleep (100)

Send ( "{TAB}")

Sleep (100)

Send ( "{TAB}")

Sleep (100)

Send ( "{TAB}")

Sleep (100)

Send ( "{TAB}")

Sleep (100)

Send ( "{TAB}")

Sleep (100)

Send ( "{TAB}")

Sleep (100)

Send ( "{RIGHT}")

Sleep (100)

ControlFocus ( "CCleaner", "Opschonen", 3 )

ControlClick ( "CCleaner", "Opschonen", 3 , "left" , 1 )

Sleep (5000) ; wacht 5 seconden

; Begin opschonen sectie Fouten

Send ( "{TAB}")

Sleep (100)

Send ( "{TAB}")

Sleep (100)

Send ( "{TAB}")

Sleep (100)

Send ( "{TAB}")

Sleep (100)

Send ( "{TAB}")

Sleep (100)

Send ( "{TAB}")

Sleep (100)

Send ( "{TAB}")

Sleep (100)

Send ( "{TAB}")

Sleep (100)

Send ( "{RIGHT}")

Sleep (100)

ControlFocus ( "CCleaner", "Scannen naar fouten", 3 )

ControlClick ( "CCleaner", "Scannen naar fouten", 3 , "left" , 1 )

Sleep (5000)

WinWait ( "CCleaner", "Herstel geselecteerde fouten..." )

ControlFocus ( "CCleaner", "Herstel geselecteerde fouten...", 4 )

ControlClick ( "CCleaner", "Herstel geselecteerde fouten...", 4 , "left" , 1 )

;Script not completed yet.

can anyone tell me what to do?

Thanks in advance!!

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...