All,
What is the major difference between the shell command and the shell execute command (besides the extra api stuff needed for shell execute) and when should I use both?
Dan Griffis
VB Programmer
Printable View
All,
What is the major difference between the shell command and the shell execute command (besides the extra api stuff needed for shell execute) and when should I use both?
Dan Griffis
VB Programmer
Dan,
Shell Execute makes a direct call to the windows API where as the VB shell command works through build in ActiveX components.
The major difference would be the size of your program, because you don't need to distribute these components with you program if you use Shell Execute. At least thats what I think :)
ShellExecute allows you to control better what's going on, and it allowes you to start a registered program by executing the file (eg. start word when you execute mydoc.doc)
But if you just want to start a program, VB's Shell funcrtion is usually enough to use.