Jump to content

Getting Status of Controls?


Recommended Posts

Hi All,

First time poster here. I've used this amazing program to create some executables to control a program I have from a home automation program (Homeseer). I've attached a picture of the program. What I'd like to do is figure out the status of the various radio buttons so that I can change them, do something then put them back to their original values.

Any tips on how I could figure out and save which radio buttons are currently selectd to be restored at a later time?

Link to comment
Share on other sites

Lookup ControlCommand in the help file.

Use AutoIt Window Info tool to give Control ID's etc.


Time you enjoyed wasting is not wasted time ......T.S. Elliot
Suspense is worse than disappointment................Robert Burns
God help the man who won't help himself, because no-one else will...........My Grandmother

Link to comment
Share on other sites

  • Developers

Hi All,

First time poster here. I've used this amazing program to create some executables to control a program I have from a home automation program (Homeseer). I've attached a picture of the program. What I'd like to do is figure out the status of the various radio buttons so that I can change them, do something then put them back to their original values.

Any tips on how I could figure out and save which radio buttons are currently selectd to be restored at a later time?

Find the name of the control with AU3Info.exe and look at ControlCommand with parameters "Check", ""....

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

Thanks fellas, The ControlCommand with IsChecked option worked like a charm.

$A_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "A", "IsChecked", "")
$B_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "B", "IsChecked", "")

$all_on_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "All On", "IsChecked", "")
$all_off_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "All Off", "IsChecked", "")

$1_on_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#1 On", "IsChecked", "")
$1_off_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#1 Off", "IsChecked", "")

$2_on_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#2 On", "IsChecked", "")
$2_off_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#2 Off", "IsChecked", "")

$3_on_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#3 On", "IsChecked", "")
$3_off_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#3 Off", "IsChecked", "")

$4_on_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#4 On", "IsChecked", "")
$4_off_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#4 Off", "IsChecked", "")

$5_on_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#5 On", "IsChecked", "")
$5_off_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#5 Off", "IsChecked", "")

$6_on_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#6 On", "IsChecked", "")
$6_off_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#6 Off", "IsChecked", "")

$7_on_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#7 On", "IsChecked", "")
$7_off_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#7 Off", "IsChecked", "")

$8_on_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#8 On", "IsChecked", "")
$8_off_status = ControlCommand ( "HACS AB8SS Configuration and Control", "", "#8 Off", "IsChecked", "")

MsgBox (0, "Speaker Status", "1 On: " & $1_on_status & @TAB & " 1 Off: " & $1_off_Status & @CRLF & "2 On: " & $2_on_status & @TAB & " 2 Off: " & $2_off_Status & @CRLF & "3 On: " & $3_on_status & @TAB & " 3 Off: " & $3_off_Status & @CRLF & "4 On: " & $4_on_status & @TAB & " 4 Off: " & $4_off_Status & @CRLF & "5 On: " & $5_on_status & @TAB & " 5 Off: " & $5_off_Status & @CRLF & "6 On: " & $6_on_status & @TAB & " 6 Off: " & $6_off_Status & @CRLF & "7 On: " & $7_on_status & @TAB & " 7 Off: " & $7_off_Status & @CRLF & "8 On: " & $8_on_status & @TAB & " 8 Off: " & $8_off_Status & @CRLF)
Edited by RoninTech
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...