PDA

View Full Version : How to read the contents of DOS window using Access VBA



AAXPW5411A
10-31-2012, 06:49 AM
Team,

Please assist me with this requirement.

I am trying to read the contents of DOS window executed using batch file.

I am doing,

1. Executing my program abc.exe using abc.bat file
2. above program opens up in dos window and keep active. This is a sort of server so it keep active and log traces time by time

All above I can do using VBA code, now I want help for, to design the code which can identify the above dos window, capture whatever the contents of it and store it in the string. Once I get the contents in the string, I can make a use of them. e.g. display.

All I want to achieve is to hide above mentioned dos window and capture the output and show it in the textbox on my form. Since there will be 100 of instances of above exe, user can simply click on running server and it will open the console output in the text box.

Some details,

OS: Windows 7 64 bit
MS Access: Access 2003
My exe program: 64 Bit DOS based software

Your help will be much appreciated.

Thanks, PW

AAXPW5411A
11-05-2012, 03:11 AM
Team,

Can anyone please help me here?

I am badly stuck and feeling helpless.. Pls :(

Thanks