vbscript - Calling one vb script to another Vb script file wont run in task scheduler -
hello , trying run vb script file in schedule task, works fine when set run administrator privileges in schedule task. when trying call second script, runs first script, second script wont run. tried run through batch file, runs first script, second script not getting call. following code first script.
dim objshell set objshell = wscript.createobject("wscript.shell") objshell.run "testscript.vbs"
not working when run through scheduler task.
could make reply. solution appreciated here..
try specifying full path testscript.vbs
. when scripts run scheduler, current directory windows system folder, not folder script being run from.
alternatively, can set current directory before calling script.
set objshell = createobject("wscript.shell") objshell.currentdirectory = "c:\scripts" objshell.run "testscript.vbs"
Comments
Post a Comment