automator08 Posted May 6, 2008 Posted May 6, 2008 Hello, i would like to wait for the state "enable" of a control (button). This button-control is part of an installation routine so it is not being created by an autoit-script at once. If the user runs the installation routine the window, on which the button-control is set, is already active, but the control is disabled for a few seconds. After this time, you can get to the next window, because the button-control has been enabled. So my question is... how can i catch the state of the button-control. I used the "GUICtrlGetState" function like this: $state = GUICtrlGetState("17501") While $state == $GUI_DISABLE ... WEnd but the function return the value -1. Can you give me some examples or inspirations to solve this problem? Thank you very much...
Triblade Posted May 6, 2008 Posted May 6, 2008 (edited) Sry, misread.. <deleted post> Edited May 6, 2008 by Triblade My active project(s): A-maze-ing generator (generates a maze) My archived project(s): Pong3 (Multi-pinger)
automator08 Posted May 6, 2008 Author Posted May 6, 2008 What is the program you are trying to install?It's a custom-made installation routine that you cannot download from the internet. So if I wrote the installtion routine with the Autoit own controls, i just beeing able to use the GUIXXX functions. Is that correct ?In my case I only have informations from the Autoit Window Info tool. With this I won the button-control-ID. It's 17501This button-control is disabled because in the back the installtion routine just make some things that doesn't matter. So this procedure takes a few seconds. After that the button getsenabled so you can go on with the rest of the installation. My question is (instead of taking the Sleep-function) how I can check the controls state?Because this is the only attribute I can check on!! Or not?Can anybody help me? (maybe with an example?)
Zedna Posted May 6, 2008 Posted May 6, 2008 While ControlCommand('Your title', "", "Button1","IsEnabled","") = 0 Sleep(50) WEnd Resources UDF ResourcesEx UDF AutoIt Forum Search
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now