Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations GregLocock on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

VB6 Running Another Program

Status
Not open for further replies.

runalot4ever

Structural
Nov 27, 2004
2
Ok I work at a store were every night we have to run a program and follow certain steps with in the program. Thw hole process takes me about 15min. I was wondering if there is any way I can write a VB6 program that will do the steps for me.
I guess im asking make a VB program were all I have to do is click one button and the VB6 program will do all the steps in the other program??

Please help!!!!!
 
Replies continue below

Recommended for you

I don't know what kind of programs you have but command line batch job can be set up to run whatever programs you want. You may have to setup some macros to do your program steps within your programs. Works great after you set the programs up properly.

Bill
 
Thank you, you have been a big help. I have one more question. Do you know of any programs that create macros for you???
 
This is certainly doable, but there are two questions that I feel you need to address.
Is there a return value issue? Do the results of one program feed into another, or is there a conditional based on the results of one program?

Is there a sequencing and timing issue? Is is necessary to wait on one program to complete before starting the next?

Good Luck
--------------
As a circle of light increases so does the circumference of darkness around it. - Albert Einstein
 
runalot4ever
Just as CajunCenturion said it is important to understand the order of the steps in your process which you want done.
If you do this with batch jobs the payback will just about be immediate.

You will have to create your own macros. Depending on what programs you are running it can be quite easy.

Be sure to test the program and try to anticipate problems such as the computer going down due to loss of power or whatever else can occur in you environment.

Bill
 
If you are running in XP you can use a simple scheduled task, or an AT command at the command prompt, you can also do a vc++ program that can handle precedence of your program via Win API to check wherever precedent task finish or not, and the same for the power and so on.
 
You may also use shell to execute the program within a VB6 app, and then use SendKeys to simulate keypresses in your program.

Regards,
Jon
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor