Run a batch file from VB app. 
Author Message
 Run a batch file from VB app.

Ok, I must be a real newby here, I just can't get a very simple project to
work...

All I am trying to do is create a very simple VB form that has a button to
click which exits the VB form and runs a batch file. That's it, but I keep
getting errors. Was trying the SHELL command but it does not like .BAT
files, and the SHELLEXECUTE I haven't made work yet either...

Is there a very simple way to click a button and run a BATCH file? I have
written several VB simple apps but this little snag has me puzzled...

Thanks for any help!



Tue, 14 Sep 2004 04:18:44 GMT  
 Run a batch file from VB app.
The simple way is to make ShellExecute work!  It spawns batch files no
problem.  Tell us what the return value of ShellExecute is and also show the
code that calls it.

Also, stop posting to those other groups that don't exist.  At least they
don't for me, and I don't think my news server is missing something...
Maybe I'm wrong.


Quote:
> Ok, I must be a real newby here, I just can't get a very simple project to
> work...

> All I am trying to do is create a very simple VB form that has a button to
> click which exits the VB form and runs a batch file. That's it, but I keep
> getting errors. Was trying the SHELL command but it does not like .BAT
> files, and the SHELLEXECUTE I haven't made work yet either...

> Is there a very simple way to click a button and run a BATCH file? I have
> written several VB simple apps but this little snag has me puzzled...

> Thanks for any help!



Tue, 14 Sep 2004 06:10:08 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Running a batch file from VB 6 app

2. VB DOS: Start Batch file after unloading app?

3. Running a batch file from VB

4. Help! Running batch files from VB

5. running multiple dos batch files from VB...

6. run Batch file in VB

7. Problems running a batch file from VB

8. VB 5 How can I close a batch file after it has been run

9. Running a DOS batch file from VB?

10. RUN A BATCH FILE FROM VB

11. Running batch file from asp file

12. Batch running of Windows apps

 

 
Powered by phpBB® Forum Software