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

Running VBScripts in Scheduler

Status
Not open for further replies.

DonP

IS-IT--Management
Jul 20, 2000
684
US
I'm trying to get a VBScript to run in the Windows 2000 Server Scheduler but so far have been unsuccessful. If I put only the path and script name, it loads into the editor rather than running the script because that's how it is accociated. I am unsure of what application actually runs VBScript and do not want to change the associations that are currently in place. It appears to be asp.dll but that is not a scheduler-type application, so I tried cmd:

C:\WINNT\system32\CMD.EXE /c dir > C:\Websites\cgi-bin\clear_temp.asp

It gives no errors but neither does it work - the script does not run. What application should I be using to run scripts this way? If it were Perl or PHP, it would be straight-forward (probably) but with VBScript, I cannot find an application with which to run it!

If this is a duplicate post, I apologize. I thought I posted the question yesterday but couldn't find it today. Don
don@pc-homepage.com
Experienced in HTML, Perl, VBScript, PWS, IIS and Apache. Run OS/2 Warp 4, BeOS v5 and Windows NT/2000 (only when I have to!)
 
Try using cscript.exe to run the VBS files. See if you have it in WINNT\System32. If not, you'll find it at MS. I've been using csript to run VBS files from the W2K Resource Kits. Hope this helps.
 
Thanks, this is all wonderful information. Still haven't gotten it to work but once I discover where in that last link to look, the answer is probably there. Don
don@pc-homepage.com
Experienced in HTML, Perl, VBScript, PWS, IIS and Apache. Run OS/2 Warp 4, BeOS v5 and Windows NT/2000 (only when I have to!)
 
OK, it looks as though it still has some issues. With this:

[tt]C:\WINNT\system32\cscript.exe //h:cscript C:\Websites\cgi-bin\clear_temp.asp[/tt]

or this:

[tt]C:\WINNT\system32\wscript.exe //h:cscript C:\Websites\cgi-bin\clear_temp.asp[/tt]

which are the same thing except that the first one gives the output to a command box and the other to a Windows popup, there is an error that an application to run .asp files cannot be found. What do I need to do differently? Don
don@pc-homepage.com
Experienced in HTML, Perl, VBScript, PWS, IIS and Apache. Run OS/2 Warp 4, BeOS v5 and Windows NT/2000 (only when I have to!)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top