[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 434
  • Last Modified:

Operate DOS exe file by VB

I am using VB to receive data from COM2 and is trying to send this data through a DOS exe file which has be programmed to send data to COM1. This DOS exe file is used to send data with 3964R protocol. For using this DOS file, I need to press 5 , then Input a string, then Enter, and finally press 1 to send the string. The string is the data that I receive from COM2. I just can not use Appactivate and Sendkeystroke to accompolish above action.
0
hueihong
Asked:
hueihong
  • 2
1 Solution
 
krustDogCommented:
I'd use VB to call a windows scripting file.  you can write them in vbscript or jscript
0
 
hueihongAuthor Commented:
I am not really clear with calling a windows scripting file. Could you make it more specific?
0
 
krustDogCommented:
I'm not sure if you've used .wsh files or (vbs, .js) files.

Sounds like you haven't used them before.

you can call your .vbs file in dos

>cscript yourfile.vbs <param1>

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/script56/html/wsconwshbasics.asp

go here to check it out.  You can run your application and wait for text and have input windows and all that.  You might want to write the whole thing in this
0
 
CleanupPingCommented:
hueihong:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
EXPERTS:
Post your closing recommendations!  No comment means you don't care.
0

Featured Post

Learn to develop an Android App

Want to increase your earning potential in 2018? Pad your resume with app building experience. Learn how with this hands-on course.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now