How to call an external executable file (.exe) from within Excel 2000


Posted by James on March 09, 2001 6:23 PM

1. How do you call an external executable file (.exe) from within Excel 2000?

Posted by Roger Redhat on March 10, 2001 12:48 AM

Use the Shell function from within a macro. E.g.

Sub Runcalc()
Dim RetVal
RetVal = Shell("C:\WINDOWS\CALC.EXE", 1)
End Sub

The 1 after the path name means that the newly opened application will have the focus and will be displayed as though you had opened it manually.




Posted by James on March 10, 2001 10:07 AM

This works nicely. Thanks Roger.