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

Running an exe file over a network share

Status
Not open for further replies.
Oct 8, 2002
62
US
i'M TRYING TO WRITE A SCRIPT TO APPLY TO MY GPO TO RUN AN EXE FILE OFF AN NETWORK SHARE. I WANT IT TO RUN AS A LOGON SCRIPT. CAN ANYONE HELP ME???????
 
Dim wsh
Set wsh = WScript.CreateObject("Wscript.Shell")
wsh.run "\\myserver\myshare\myexe.exe",,True


where the True means wait on completion then continue procesing the script, this is not 100% successfull as if the program starts a new thread and terminates the first one the wsh.run will presume it has completed and will carry on with the script processing.

Hope it helps

Regards
Steve Friday
 
I get an error on line 3 char 1 saying can't find network after i plug my values in. any ideas??????????
 
Are you server you have the values set correctly, I just tested with one of mine and it worked.

Also do you have spaces in your share names?

does the error say "The network path was not found", if it does then either server name or share name is incorrect.

Regards
Steve Friday
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top