Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

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

Running External Programs

Status
Not open for further replies.

softlad

Programmer
Mar 20, 2001
9
GB
Hi

I have a program (.exe) which I want to run from a Button on a form. I have managed to create a .bat file and put the command in there and can execute this using the 'Shell' option. The problem is, is that its ugly and puts the users 'Off'. I have created a shortcut (.pif) file and this can run it minimised, which is a large improvment. However, I can't run this from this Button (at least I don't know how. )
My question is, Is it possible to run external programs without the DOS Shell OR How do I run this Shortcut (.PIF) using a Button on a Form.

Thanks In Advance

Ricko
 
The shell command can run an executable directly, if that is your question. I think it's syntax is:
Shell("Command Path & Name")

HTH James Goodman
j.goodman00@btinternet.com
 
With the shell command you can also define, how you run application (with no focus, hidden etc.).

Shell("Command Path & Name",WindowStyle)

See the DropDown list, when you type comma after path.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top