Jump to content

benson

Members
  • Posts

    11
  • Joined

  • Last visited

benson's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. done that, same problem. is it possible that the ControlCommand("WIN", "TAB", "ComboBox1", "SelectString", "ITEM") im using makes the window select the item causing the msg box to pop up even before reaching the line? ive tried using msgbox to check whether the script is running but it doesnt work. MsgBox(0,"1","1") ControlCommand("MSG", "TAB", "ComboBox1", "SelectString", "ITEM") MsgBox(0,"1","2") Output of the above code is: MsgBox 1 pops up, then the popup window with the ok button displays before popping up MsgBox 2. It seems
  2. yep im sure everything else is working. i even tried putting a msgbox inside the if WinExist statement. The msgbox doesnt pop up. but if i simulate the program manually, it works. is it possible that using select string will select a combo item before it is even processed?
  3. For example, i'm currently running a set of processes that changes configurations for a program. It's being looped using While WEnd loop. there are times it just keeps on going with the process and there are times when a window with an ok button pops up (like a msgbox). my code uses the SelectString to change the combo box options. when a particular selection is made, it automatically pops up the msgbox. While ..... set ComboBox item using SelectString If WinExists("pop up box") Then WinActivate("pop up box") WinWaitActive("pop up box") ControlClick("pop up box", "", "Button1") ; ok button EndIf Wend the above code doesn't seem to work with the whole program but it works if i simulate manually, select the item in the combo and run the WinExists alone. How do i make AutoIt detect the new window and click the ok button of the new window automatically. Thanks.
  4. For example, i'm currently running a set of processes that changes configurations for a program. It's being looped using While WEnd loop. there are times it just keeps on going with the process and there are times when a window with an ok button pops up (like a msgbox). my code uses the SelectString to change the combo box options. when a particular selection is made, it automatically pops up the msgbox. While ..... set ComboBox item using SelectString If WinExists("pop up box") Then WinActivate("pop up box") WinWaitActive("pop up box") ControlClick("pop up box", "", "Button1") ; ok button EndIf Wend the above code doesn't seem to work with the whole program but it works if i simulate manually, select the item in the combo and run the WinExists alone. How do i make AutoIt detect the new window and click the ok button of the new window automatically. Thanks.
  5. Hi how can i detect a window that just recently popped up? example, an automation process is currently running then a window suddenly pops up, i want to close the newly popped up window automatically. is it ok to use WinActive or is there other, better options? Thanks
  6. Hi For example, i have a program that starts a process after clicking a start button. How do i make the program MINIMIZE TO THE SYSTEM TRAY after clicking the start button? After it runs the program, how do i make it restore automatically? Thanks.
  7. How do i count the number of elements in an array? example, $array = stringsplit("mon|tue|wed|thurs|fri", "|") the number of elements is 5, how do i make $array output 5? thanks.
  8. Thanks for the info. Its been a great help.
  9. I need help in moving from one system tab to the other after setting an option for the current tab. example, video settings has the following tabs: Themes, Desktop, Screen Saver, Appearance, Settings. After automatically opening the video properties window, changing an option in the Themes tab, it must then automatically move to the Desktop tab. Thanks
  10. Thanks for the answers guys, they helped solve my problem, btw, i noticed "144" and "80" from the code below. If GUICtrlRead($ListBox) = "Select Item" Then If GUI CtrlGetState($Button) < 144 Then GUICtrlSetState($Button, 144) Else If GUICtrlGetState($Button) <> 80 Then GUICtrlSetState($Button, 80) EndIf What are they for? Thanks
  11. Im new in using AutoIt and i have a small problem, how do i disable or gray-out a button when a condition is not met? for example, a listbox has a default value "Select item", if the value isnt changed, the button should be grayed out unless the listvalue is changed. thanks
×
×
  • Create New...