Jump to content

romanais

Members
  • Posts

    4
  • Joined

  • Last visited

Everything posted by romanais

  1. Hello, i think that there's a typo on your "Example of my script using _ImageSearchArea". With this line : local $search = _ImageSearchArea('check5.bmp', 1, 800, 40, 900, 80, $x, $y, 0)Local $search = _ImageSearch('checkImage.bmp', 0, $x, $y, 0)
  2. Can you try this please ? Opt("WinTextMatchMode", 2) ;1=complete, 2=quick Opt("WinTitleMatchMode", 2) ;1=start, 2=subStr, 3=exact, 4=advanced, -1 to -4=Nocase Run('MSIEXEC.EXE /I secureclientinstaller.msi') _WinWaitActivate("SecureAssess Central - SecureClient AAT","") ControlClick("SecureAssess Central - SecureClient AAT", "", "[CLASS:TAeroButton; INSTANCE:3]") _WinWaitActivate("SecureAssess Central - SecureClient AAT","Destination Folder") Send("C:\Program Files\SecureAssess Central - SecureClient AAT") ControlClick("SecureAssess Central - SecureClient AAT", "", "[CLASS:TAeroButton; INSTANCE:3]") _WinWaitActivate("SecureAssess Central - SecureClient AAT","") ControlClick("SecureAssess Central - SecureClient AAT", "", "[CLASS:TAeroButton; INSTANCE:3]") Func _WinWaitActivate($title,$text,$timeout=0) WinWait($title,$text,$timeout) If Not WinActive($title,$text) Then WinActivate($title,$text) WinWaitActive($title,$text,$timeout) EndFunc
  3. Hello, WinWaitActive can do the job. See help file : For example, I use this to install a software @work : Func _WinWaitActivate($title,$text,$timeout=0) WinWait($title,$text,$timeout) If Not WinActive($title,$text) Then WinActivate($title,$text) WinWaitActive($title,$text,$timeout) EndFunc Run('install.exe') _WinWaitActivate("Ciel Paye Evolution","ATTENTION : Ce progr") Send("{ALTDOWN}s{ALTUP}") _WinWaitActivate("Ciel Paye Evolution","Je n'accepte pas les") Send("{UP}") Send("{ALTDOWN}s{ALTUP}") _WinWaitActivate("Ciel Paye Evolution","Installatio&n standa") Send("{ALTDOWN}s{ALTUP}") _WinWaitActivate("Ciel Paye Evolution","Toutes les informati") Send("{ALTDOWN}i{ALTUP}") _WinWaitActivate("Ciel Paye Evolution","L'InstallShield Wiza") Send("{SHIFTDOWN}{TAB}{SHIFTUP}") Send("{SPACE}") Send("{ALTDOWN}t{ALTUP}") ;terminate the install With this, the speed of computer doesn't matter. The script always waits for the next window, with the good title and the good text. I also use this code to click on a cancel button. ControlClick("Ciel Paye Evolution", "", "[CLASS:Button; INSTANCE:4]") You can use Autoit window info to find the infos (text, classname, etc) I hope this will help you !
  4. Hello, and thank you ! I tested your script, and I've no problem with consecutive uses. I just changed sleep( $WaitTime ) to sleep( $WaitTime * 1000) So I can use your function with Wait(10) ;time in seconds
×
×
  • Create New...