Jump to content

What we can do with the ouput of "WinGetClassList" and "ControlGetHandle"


Recommended Posts

Hi all,

What we can do with the output of these two functions.

1. WinGetClassList

2. ControlGetHandle

If this is a silly question, please forgive me. 

Spoiler

My Contributions

Glance GUI Library - A gui library based on Windows api functions. Written in Nim programming language.

UDF Link Viewer   --- A tool to visit the links of some most important UDFs 

 Includer_2  ----- A tool to type the #include statement automatically 

 Digits To Date  ----- date from 3 integer values

PrintList ----- prints arrays into console for testing.

 Alert  ------ An alternative for MsgBox 

 MousePosition ------- A simple tooltip display of mouse position

GRM Helper -------- A littile tool to help writing code with GUIRegisterMsg function

Access_UDF  -------- An UDF for working with access database files. (.*accdb only)

 

Link to comment
Share on other sites

JohnOne, can i get the text on a control with a control handle. I have tested but it did not work.

Local $Window_title = "Nuendo - [Nuendo Project - 273-278.npr]"

Local $Control_handle = ControlGetHandle($Window_title,"",1)
Local $Control_txt = ControlGetText($Window_title,$Control_handle,1)
Alert($Control_txt)

This is my code. I have tested but not working

And please look this image. This is an audio editor. I need the data in the time display panel. Look the arrow. Window info tool shows "1" as ID.

post-89644-0-05129400-1425907138_thumb.j

Edited by kcvinu
Spoiler

My Contributions

Glance GUI Library - A gui library based on Windows api functions. Written in Nim programming language.

UDF Link Viewer   --- A tool to visit the links of some most important UDFs 

 Includer_2  ----- A tool to type the #include statement automatically 

 Digits To Date  ----- date from 3 integer values

PrintList ----- prints arrays into console for testing.

 Alert  ------ An alternative for MsgBox 

 MousePosition ------- A simple tooltip display of mouse position

GRM Helper -------- A littile tool to help writing code with GUIRegisterMsg function

Access_UDF  -------- An UDF for working with access database files. (.*accdb only)

 

Link to comment
Share on other sites

  • Moderators

Um... Pretty sure that WinGetClassList returns an array... :whistle:

Edit:

Are you sure you can get the text from that control?

When you put AutoInfo tool over the control, do you see text in the text output area?

In my experience, those types of controls are generally drawn, if they're not in the "COM" (if it's available) then you very well may need to do an OCR.  Without getting into that, you'd also need to check if IUIAutomation can get the data if AutoInfo tool can't, because if there's no data from AutoInfo tool, then ControlGetText is probably useless.

Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

@JohnOne, 2nd parameter is the handle of that control. Infact, i have tested with an empty string as 2nd param. But no way.

@SmokeN, Is there any OCR tool to work with autoit code ?. Because IUAutomation didn't give any better result than Window info Tool.

Spoiler

My Contributions

Glance GUI Library - A gui library based on Windows api functions. Written in Nim programming language.

UDF Link Viewer   --- A tool to visit the links of some most important UDFs 

 Includer_2  ----- A tool to type the #include statement automatically 

 Digits To Date  ----- date from 3 integer values

PrintList ----- prints arrays into console for testing.

 Alert  ------ An alternative for MsgBox 

 MousePosition ------- A simple tooltip display of mouse position

GRM Helper -------- A littile tool to help writing code with GUIRegisterMsg function

Access_UDF  -------- An UDF for working with access database files. (.*accdb only)

 

Link to comment
Share on other sites

  • Moderators

I sincerely don't trust them unless I've written them myself for the task at hand.  And it's certainly not something I'd use throughout my company or commercially.

Have you tried contacting the vendor?

Edit:

And as JohnOne said... your parameters are wrong:

ControlGetText($Window_title, "", $Control_handle)

Or

ControlGetText($Control_handle, "", "")

Might work.

Or

WinGetText($Control_handle, "")

Might even work.

Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

Thank you @SomkeN and @JohnOne

Spoiler

My Contributions

Glance GUI Library - A gui library based on Windows api functions. Written in Nim programming language.

UDF Link Viewer   --- A tool to visit the links of some most important UDFs 

 Includer_2  ----- A tool to type the #include statement automatically 

 Digits To Date  ----- date from 3 integer values

PrintList ----- prints arrays into console for testing.

 Alert  ------ An alternative for MsgBox 

 MousePosition ------- A simple tooltip display of mouse position

GRM Helper -------- A littile tool to help writing code with GUIRegisterMsg function

Access_UDF  -------- An UDF for working with access database files. (.*accdb only)

 

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

×
×
  • Create New...