Sign in to follow this  
Followers 0
doomkiller

Reading text froma dos window?

4 posts in this topic

I was talking a look at autoit window info and there were no classes or any visisble text showing up. Looked at a few functions none seemed what i needed. I need to read text from a dos-prompt window that is already open is it possible?

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

I was talking a look at autoit window info and there were no classes or any visisble text showing up. Looked at a few functions none seemed what i needed. I need to read text from a dos-prompt window that is already open is it possible?

Well, if you typed a command to get that text, you can add ">> textfile.txt" at the end and the results of the command will be saved to the text file. Then you can use AutoIt to extract the text from the text file if you are so inclined.

Edit: You can also send a mouseclick (right-click) to the DOS window (@ComSpec) and then Send ("S{ENTER}") to capture the text to the clipboard.

Edited by SerialKiller

Share this post


Link to post
Share on other sites

this may be of some use: StdoutRead


[right][font="Courier New"]...Run these streets all day, I can sleep when I die.[/font] [/right]

Share this post


Link to post
Share on other sites

I need to read text from a dos-prompt window that is already open is it possible?

Not at this stage unfortunately. You'll need to consider the options posted above.

The beta's StdOutRead() function is an excellent way of reading information from a program if circumstances allow you to open that program using AutoIt first. There's no longer a need for redirecting an output to a temporary file and there's also the advantage of reading output as it happens; not needing to wait until the process has finished.

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