Jump to content

WinGetHandle


Recommended Posts

Hello all,

1. I am working on the Windows scientific calculator.

Please review this script:

If WinExists("Calculator") Then

$hBtn1 = WinGetHandle("Calculator", "Sta")

MsgBox(0, "hBtn1", $hBtn1)

$hBtn2 = WinGetHandle("Calculator", "CE")

MsgBox(0, "hBtn2", $hBtn2)

EndIf

Why do I get the same value for both of the buttons?

Unfortunately I am quite sure I am not using the function correctly... :-(

2. On larger applications, it takes me even 20 seconds until I get the handle. Is there a faster way to get a button handle, given only the text on it?

Thanks.

Edited by dushkin
Link to comment
Share on other sites

OK OK - Got it!!!!

(Is there a way to remove topics???)

Hello all,

1. I am working on the Windows scientific calculator.

Please review this script:

If WinExists("Calculator") Then

$hBtn1 = WinGetHandle("Calculator", "Sta")

MsgBox(0, "hBtn1", $hBtn1)

$hBtn2 = WinGetHandle("Calculator", "CE")

MsgBox(0, "hBtn2", $hBtn2)

EndIf

Why do I get the same value for both of the buttons?

Unfortunately I am quite sure I am not using the function correctly... :-(

2. On larger applications, it takes me even 20 seconds until I get the handle. Is there a faster way to get a button handle, given only the text on it?

Thanks.

Edited by dushkin
Link to comment
Share on other sites

OK OK - Got it!!!!

(Is there a way to remove topics???)

We would rather you didn't.

This forum builds a searchable history of questions and answers, and we encourage users to search before posting questions. There won't be anything to search if topics are deleted as the questions are answered.

:idea:

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
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...