Sign in to follow this  
Followers 0
m0ngs

how to click class without title?

8 posts in this topic

the title is empty and the class is

WindowsForms10.Window.8.app.0.2bf8098_r11_ad1

thanks in adv.!

Share this post


Link to post
Share on other sites



If you look at the example for ControlClick you will see a way to do it:

$window = WinWait("[CLASS:<classname>]", "")
ControlClick($window, "", <ControlID>)

√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

sorry but still not working i make

$window = WinWait("[CLASS:WindowsForms10.Window.8.app.0.2bf8098_r11_ad1]", "")
ControlClick($window, "", 16910374)
 
is the control id is right? 
i got it in "Control" then the one "ID" on it..
and i cant do the mouseclick coz it pop up everywhere..
Edited by m0ngs

Share this post


Link to post
Share on other sites

How would we know what the control ID is?? How about you post a screenshot of what the AutoIt Window Info Tool shows for that control?


√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites

the one with the "ID"

2usirki.png

hope it work now

thanks

Share this post


Link to post
Share on other sites

Your screenshot has a diff ID than you attempted to click.

Also, you should add debugging to see if you actually find the handle for your window, or if it's failing to find it...winwait waits indefinitly if you don't add a timeout.


IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window.

Share this post


Link to post
Share on other sites

#7 ·  Posted (edited)

ahh i see it gives different id everytime i open it..

do i still locate it even it gives different id everytime?

and how bout the controlclick coords?

how can i use to click yhere?

i notice that its the same controlclick coords position in that window..

Edited by m0ngs

Share this post


Link to post
Share on other sites

#8 ·  Posted (edited)

I have one of those window forms apps that I've automated.

It's broken up into groups.  Each group has a button.

I grabbed the groups, verified which group it was by the text, and then looped through all buttons until I found the one within the bounds of the group.

I should revisit it, to find a better way, but it works as I require it.

...may or may not work for you, but something to think about.

Edited by jdelaney

IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window.

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