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

CreateObject("WScript.Shell") wont work on Windows 2000 Server

Status
Not open for further replies.

lauraSatellite

Technical User
Jul 22, 2004
35
IE
Hi, I have a script that contains:

set shell = CreateObject("WScript.Shell")
currentDir = shell.CurrentDirectory

I tested this script on a server at work, and it ran fine. I have just installed Windows 2000 server on my own computer, and am trying to get the same script to run on this server. The script bombs out saying:
Error: Object doesn't support this property or method: shell.CurrentDirectory
Code: 800A01B6
If i comment out the above two line of code, and replace them with currentDir = "C:\WhateverFolder" the script runs fine.
Any input as to what might be wrong here would be greatly appreciated.
Thanks.
 
What version of ScriptEngine ?

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
I just installed windows scripting host v 5.6 and its working away now.
Thanks,
-Laura
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top