Jump to content
Sign in to follow this  
lewcamino

Button Click

Recommended Posts

lewcamino

Heres another fun one...

Is it possible to tell what button a user has pressed (clicked) in a window?

Example;

Call from 13125551234

[accept] [reject]

Is there a was to tell what the user pressed?

PS. This is not my dialog box, as in it is from another program, blutooth headset profile on the computer to be exact.

Any info would help ofcourse, thanx in advance.

Thanx; Lew

Share this post


Link to post
Share on other sites
buzz44

Find out what title the window changes after each button has been pressed, then simply check what it changed to. Ofcourse this won't work if the title doesn't change lol.

Edited by Burrup

qq

Share this post


Link to post
Share on other sites
svennie

Heres another fun one...

Is it possible to tell what button a user has pressed (clicked) in a window?

Example;

Call from 13125551234

[accept] [reject]

Is there a was to tell what the user pressed?

PS. This is not my dialog box, as in it is from another program, blutooth headset profile on the computer to be exact.

Any info would help ofcourse, thanx in advance.

Thanx; Lew

While 1
    $text=ControlGetText("Incoming call","",ControlGetFocus("Incoming call"))
    If $text = "Accept" Then
    ;code when accepted
        ExitLoop
    ElseIf $text = "Reject"
    ;code when rejected
        ExitLoop
    EndIf
WEnd

Hopefully it helps you ;) .


Sorry for my English, I'm Dutch... =DMedia UDFINet Adv UDF

Share this post


Link to post
Share on other sites
LxP

You could always write code to hide the window asking the question and write an AutoIt GUI that mimics the information shown on that other window. The user will click a button on your AutoIt GUI, your AutoIt code will know what the user wants to do, it can pass that information to the other window and carry out any necessary actions before/after it does so.

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  

×