Jump to content

Having Trouble Clicking 2 buttons in 2 screen


Recommended Posts

Hi,

I've been working on a script to make the installation of "Windows Media Player 11" automatic.

Here is the script i've been making the start with:

#include <GUIConstantsEx.au3>
    GUISetState(@SW_SHOW)
Run('C:\Documents and Settings\ICT.SKOBA\Bureaublad\wmp11-windowsxp-x86-nl-nl.exe')
WinWaitActive("Windows Media Player 11", "Bezig met uitpakken")
WinWaitActive("Windows Media Player 11", "Vali&deren")
Send("!d")
WinWaitActive("Windows Media Player 11", "Ik ga &akkoord")
Send("!a")
WinWaitActive("Windows Media Player 11", "Systeemherstel is uitgeschakeld")
Send("{ENTER}")
Exit

But now i've bumped into the following problem:

Posted Image

Its a radio button and dont know how to check it. I know its checked now but I did this manually.

The point is that it needs to be checked automaticly.

Can someone help me out?

Thanx in advance,

teunvisser

Link to comment
Share on other sites

I'm able to check the Radio Button now..

But now i need to click the "Voltooien" Button after checking the radio button.

I've tried:

#include <GUIConstantsEx.au3>
    GUISetState(@SW_SHOW)
Run('C:\Documents and Settings\ICT.SKOBA\Bureaublad\wmp11-windowsxp-x86-nl-nl.exe')
WinWaitActive("Windows Media Player 11", "Bezig met uitpakken")
WinWaitActive("Windows Media Player 11", "Vali&deren")
Send("!d")
WinWaitActive("Windows Media Player 11", "Ik ga &akkoord")
Send("!a")
WinWaitActive("Windows Media Player 11", "Systeemherstel is uitgeschakeld")
Send("{ENTER}")
WinWaitActive("Windows Media Player 11", "&Snelle instellingen (aanbevolen)")
Send("!s")
Send("{TAB}")
Send("{TAB}")
Send("{ENTER}")
Exit

But Tabbing doesnt seem to work.. it doesnt autoclick the "voltooien" button.

Any suggestions on what I should do?

Thanx in advance,

Teun

Link to comment
Share on other sites

googling WMP silent install yielded this: M$ silent install maker

and: you're not supposed to bump your thread within 24h

whim

edit: oops, sorry - it doesn't support WMP 11

I started this thread 4 days ago..

And i'm sorry but this doesnt really help :D

I need to know how to press the "voltooien" button after checking the radio button. "Snelle instellingen aanbevolen".

Link to comment
Share on other sites

Hi Teun,

there are a variety of functions available which can automate windows without directly reproducing user input. This involves simulating the messages which Windows sends to the window if a button or control is pressed.

You can use this to click the "Voltooien" button without someone actually clicking it. This means the window, in all likelyness, doesn't have to be active either.

The functions to do this all start with Control, and can be found in the help file under Function Reference > Window Management > Controls.

The function you are looking for to click the button is ingeniously named ControlClick.

Hope this helps,

Manadar

Edited by Manadar
Link to comment
Share on other sites

The problem is not that i dont know how to click the button..

But the problem is that the screen does my !o before the actual "voltooien" screen is active..

WinWaitActive does NOT work.. i've tried about everything.

Cant seem to figure it out!

some1 give me the golden tip please :D,

Teun

ps. I've been trying to do it with TAB TAB TAB ENTER.. also this does NOT work >.< its like it doesnt recognize the Voltooien button.

I'm out of ammo now.. dont know what to do!

Link to comment
Share on other sites

Hi again everyone,

I've been working on a script that makes the installing of the Dutch version of Windows Media Player 11 go automatic.

But i'm suck on this one bit now and its driving me insane.

The thing is:

Posted Image

I'm able to check the Radiobutton.. thats real easy.

But after I checked the radiobutton "Snelle Instellingen (Aanbevolen)"

I want the click the button: "Voltooien".

I've tried everything but i can't get the button to get clicked..

Its like it times-out after checking the Radiobutton and then it doesnt give his click to the "Voltooien" Button.

I think the click on the "Voltooien" is done before the actual screen is active.

I've tried everything but nothing seems to work.

Here is my code:

#include <GUIConstantsEx.au3>
    GUISetState(@SW_SHOW)
Run('C:\Documents and Settings\ICT.SKOBA\Bureaublad\wmp11-windowsxp-x86-nl-nl.exe')
WinWaitActive("Windows Media Player 11", "Bezig met uitpakken")
WinWaitActive("Windows Media Player 11", "Vali&deren")
Send("!d")
WinWaitActive("Windows Media Player 11", "Ik ga &akkoord")
Send("!a")
WinWaitActive("Windows Media Player 11", "Systeemherstel is uitgeschakeld")
Send("{ENTER}")
WinWaitActive("Windows Media Player 11", "&Snelle instellingen (aanbevolen)")
Send("!s")
WinWaitActive("Windows Media Player 11", "Volt&ooien")
Send("!o")
Exit

Hope you guys can get me to the next step......... cause its really working on my nerves.

Thanx,

Teun

Link to comment
Share on other sites

#include <GUIConstantsEx.au3>
    GUISetState(@SW_SHOW)
Run('C:\Documents and Settings\ICT.SKOBA\Bureaublad\wmp11-windowsxp-x86-nl-nl.exe')
WinWaitActive("Windows Media Player 11", "Bezig met uitpakken")
WinWaitActive("Windows Media Player 11", "Vali&deren")
Send("!d")
WinWaitActive("Windows Media Player 11", "Ik ga &akkoord")
Send("!a")
WinWaitActive("Windows Media Player 11", "Systeemherstel is uitgeschakeld")
Send("{ENTER}")
WinWaitActive("Windows Media Player 11", "&Snelle instellingen (aanbevolen)")
Send("!s")
$WinTitle = "Windows Media Player 11"
ControlClick($WinTitle, "", "Button9")
Exit

Like that?

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...