Jump to content

how to "read" button toggletogglestate


Recommended Posts

.... from an onscreen button...

This is driving me nuts, since a full week...

using UIAWrappers.au3

Through UIA_Getobject found the button on screen

I can click it with an UIA_ action, and this works

How can I get the toggle state in a local variable?

Any help very appreciated, Thanks

Jake, senior retired programmer

Link to post
Share on other sites

#include <UIAWrappers.au3>

Local $OOp0,$OOp1,$OOpx
Local $statxt

 $OOp1=_UIA_getObjectByFindAll($UIA_oDesktop, "Title:=My ApplicationJT;controltype:=UIA_WindowControlTypeId;class:=MainWindow", $treescope_children)
  _UIA_Action($OOp1,"setfocus")
  $OOp0=_UIA_getObjectByFindAll($OOp1, "Title:=;controltype:=UIA_GroupControlTypeId;class:=QWidget", $treescope_children)
  $OOpx=_UIA_getObjectByFindAll($OOp0, "title:=Enable;ControlType:=UIA_CheckBoxControlTypeId", $treescope_subtree)
  _UIA_action($OOpx,"highlight")
   MsgBox(1,"",_UIA_getPropertyValue($OOpx,"ToggleToggleState"))
   $statxt = _UIA_ToggleToggleState($OOpx)
   MsgBox(1,"",$statxt)

 

anyone... please?

Link to post
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
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...