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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Change to Mapped Drive & Execute .EXE file

Status
Not open for further replies.

wreded

Technical User
Dec 18, 2001
119
US
First time i've needed VBS. Got the mapping just don't know how to change to mapped drive and start required executable file.
i looked in Forum and FAQs and didn't find what i needed/wanted (though i DID find a few other things that'll help in other ways).
Thanks,
Dave
 
To execute the app you don't actually need to change directory to the mapped drive, you can just specify the whole pathname:

Code:
Dim EXEFILE
EXEFILE = "Path to exe file here"

Set oWshell = CreateObject("WScript.Shell")
oWshell.Run EXEFILE
Set oWshell = Nothing

This is effectively the same as running the exe file from the command line.

Cheers,
Dave

"Yes, I'll stop finding bugs in the software - as soon as you stop writing bugs into the software." <-- Me

For all your testing needs: Forum1393
 
Dave,
Thanks! i'll give 'er a try right now.
Dave
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top