Sign in to follow this  
Followers 0
johnirvin

Please I need help so badly

7 posts in this topic

Hi guys,

Is there any way (function, code, etc.) to read contents from an active window? Please help me. I am just sick of messing up with this automation. Tnx.

Share this post


Link to post
Share on other sites



Hi guys,

Is there any way (function, code, etc.) to read contents from an active window? Please help me. I am just sick of messing up with this automation. Tnx.

It depends on the window, but WinGetText() works in most cases. What kind of window are you reading "contents" from?

:D


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

Share this post


Link to post
Share on other sites

It depends on the window, but WinGetText() works in most cases. What kind of window are you reading "contents" from?

:D

OK. Would it be able to get all the text in it or just some. Tnx for your answer. You don't have any idea how much it helped me. God Bless.

Share this post


Link to post
Share on other sites

It depends on the window, but WinGetText() works in most cases. What kind of window are you reading "contents" from?

:D

How do i go about getting the text from a window, if i only have the 'title'.

E.g. The window has 3 lines of text and i only want to get the text from the 2nd line.

Text 1

Text 2

Text 3

Share this post


Link to post
Share on other sites

OK. Would it be able to get all the text in it or just some. Tnx for your answer. You don't have any idea how much it helped me. God Bless.

It will be able to get all the text in the window including captions of a button.

Share this post


Link to post
Share on other sites

How do i go about getting the text from a window, if i only have the 'title'.

E.g. The window has 3 lines of text and i only want to get the text from the 2nd line.

Text 1

Text 2

Text 3

You have to specify the window somehow. If you provide the title parameter, the text parameter is optional.

You can't just get a particular line from the window, but you could use different commands to do that if the text is part of a control, for example an Edit control.

Enough theoretical discussion. Exactly what kind of window are you reading? Have you coded a short test script to try anything out?

:D


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

Share this post


Link to post
Share on other sites

#7 ·  Posted (edited)

In the full AutoIt suite, there is the AutoIt Window Info tool. It should give you the info you need. Then look at the examples for the Windows mamagement in the helpfile. Try each example in SciTe and you should get the idea pretty quick. If this still confuses you, then take a look at this:

AutoIt 1-2-3

Edited by Volly

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