Sign in to follow this  
Followers 0
LibiO

How can I find and click on the checkbox?

5 posts in this topic

post-53266-0-97914000-1306847932_thumb.ppost-53266-0-97914000-1306847932_thumb.pHello!

I need to find and click the checkbox, which is located at:

Control Panel -> Windows Update - > Select Updates to install:

then, there are many updates there (with their checkboxes)

Picture is attached.

I want to choose a specific one, and to mark it on its checkbox.

How can I click on any checkbox? AutoIt Window Info does not see it as a control.

Thanks!!!

Share this post


Link to post
Share on other sites



Try to use IE UDF.

That wouldn't work because the screen shot shows the control panel, not IE.

This may work (sending CTRL-A to select all):

send ("^a")

But I cannot test it right now. If that doesn't work, I think setting the focus to the first item and sending a space and then a down arrow would most definitely do the trick.


#include <ByteMe.au3>

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

If the script is just for you, you could use cordinates to click the "check all checkboxes"-checkbox.

@sleepydvdr: Space+Down works

Edit:

Forgot to add this:

HotKeySet("^m","test")
HotKeySet("^n","runner")

Func test()
Global $handle
$handle = WinGetHandle("Velg oppdateringer som skal installeres"); Window title in norweigan
MsgBox(0,"",$handle);Just to see that i got the correct handle
ControlFocus($handle,"", "[CLASS:WuDuiListView; INSTANCE:1]");Sets the focus

EndFunc

Func runner()
    Send("{Space}")
    Send("{Down}")
EndFunc

While 1
    Sleep (40)
WEnd

Problem with the Space+down thing is if the check box is checked it will uncheck it.

I am a noob and i dont know the most, but shouldnt there be anything that can get that checkbox as a variable so someone can write Click ($checkbox)... ?

Edited by Maffe811

[font="helvetica, arial, sans-serif"]Hobby graphics artist, using gimp.Automating pc stuff, using AutoIt.Listening to music, using Grooveshark.[/font]Scripts:[spoiler]Simple ScreenshotSaves you alot of trouble when taking a screenshot!Don't remember what happened with this, but aperantly the exe is all i got.If you don't want to run it, simply don't._IsRun UDFIt figures out if the script has ben ran before based on the info in a ini file.If you don't want to use exactly what i wrote, you can use it as inspiration.[/spoiler]

Share this post


Link to post
Share on other sites

It can help!

Thanks!

If the script is just for you, you could use cordinates to click the "check all checkboxes"-checkbox.

@sleepydvdr: Space+Down works

Edit:

Forgot to add this:

HotKeySet("^m","test")
HotKeySet("^n","runner")

Func test()
Global $handle
$handle = WinGetHandle("Velg oppdateringer som skal installeres"); Window title in norweigan
MsgBox(0,"",$handle);Just to see that i got the correct handle
ControlFocus($handle,"", "[CLASS:WuDuiListView; INSTANCE:1]");Sets the focus

EndFunc

Func runner()
    Send("{Space}")
    Send("{Down}")
EndFunc

While 1
    Sleep (40)
WEnd

Problem with the Space+down thing is if the check box is checked it will uncheck it.

I am a noob and i dont know the most, but shouldnt there be anything that can get that checkbox as a variable so someone can write Click ($checkbox)... ?

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