Sign in to follow this  
Followers 0
ankushsingh

Control commands (IsVisible and IsEnabled) not working properly

4 posts in this topic

#1 ·  Posted (edited)

Hi All

I am using following code and getting same value "0" irrespective object is checked or unchecked.

$val=1

WinActivate("Application Client")

$val=ControlCommand("Application Client","Connect","[CLASS:WindowsForms10.BUTTON.app.0.33c0d9d; INSTANCE:9]","IsChecked","");

MsgBox(0,"Chack Connect checkbox",$val)

This statement always returns "0". but same "value of Class and instance" using with "Controlclick" command it is working fine and clicking on right object.

Please help me how to get the right value for control commands.

same issue facing with all control commands like (IsVisible, IsEnable).

Edited by ankushsingh

Share this post


Link to post
Share on other sites



Hi All

I am using following code and getting same value "0" irrespective object is checked or unchecked.

$val=1

WinActivate("Application Client")

$val=ControlCommand("Application Client","Connect","[CLASS:WindowsForms10.BUTTON.app.0.33c0d9d; INSTANCE:9]","IsChecked","");

MsgBox(0,"Chack Connect checkbox",$val)

This statement always returns "0". but same "value of Class and instance" using with "Controlclick" command it is working fine and clicking on right object.

Please help me how to get the right value for control commands.

same issue facing with all control commands like (IsVisible, IsEnable).

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

I'm having a very similar issue. All of these attempts return 0 regardless of the state of the checkbox (I've pushed them all into a MsgBox and supplied the results).), despite the information gleaned from AutoIt v3 Window Info:

$text = ""

$title = WinGetTitle("My Window" ,$text)

  • MsgBox(1,"test", ControlCommand($title,$text,"[CLASS:WindowsForms10.window.8.app.0.378734a; INSTANCE:6]","IsChecked", "") & @CRLF &"--"& @CRLF & @error)

    • 0

      --

      1

  • MsgBox(1,"test", ControlCommand($title,$text,"[CLASSNN:WindowsForms10.window.8.app.0.378734a6]","IsChecked", "") & @CRLF &"--"& @CRLF & @error)

    • 0

      --

      1

  • MsgBox(1,"test", ControlCommand($title,$text,"WindowsForms10.window.8.app.0.378734a6","IsChecked", "") & @CRLF &"--"& @CRLF & @error)

    • 0

      --

      1

  • MsgBox(1,"test", ControlCommand($title,$text,"TEXT:Control Text as pulled from Au3 WinInfo","IsChecked", "") & @CRLF &"--"& @CRLF & @error)

    • 0

      --

      0

The only difference is that ControlClick() doesn't work for me either. Edited by VertigoRay

Figure IT out!http://vertigion.com

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

It just clicked after all morning of working on this. I posted here and had a revelation!

SciTE was running as DomainUsername while the window I was trying to manipulate and test was running as ComputerNameAdministrator. The window I was trying to manipulate had required Admin Elevation. I hope this helps others! My issue is solved!

Edited by VertigoRay

Figure IT out!http://vertigion.com

Share this post


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
Sign in to follow this  
Followers 0