Get to know the Windows Scripting Host in Windows 2000
Takeaway: The Windows Scripting Host (WSH) is a powerful scripting tool. Learn how to use WSH in Windows 2000 Server.
If you're relatively new to administrating Windows Server 2000, you might not realize that you have a powerful scripting tool at your disposal. This tool can help you automate administrative tasks such as backups, user administration, and more.Windows Server 2000 includes the Windows Scripting Host (WSH). WSH supports scripts written in VBScript, which is very similar to Visual Basic for Applications (VBA), and Jscript, loosely modeled on the Java programming language.
But don't make the mistake of thinking WSH's uses stop at relatively simple tasks. In fact, it features a broad range of capabilities to automate processes, extract information from the system, and even provide management functions through Simple Network Management Protocol (SNMP).
Of course, learning to use scripts takes time and an affinity for programming. To get an idea of WSH, here's a simple script to help you get your feet wet. Enter the following into a text file, save it as Hello.vbs, and double-click the new file to execute it.
dim user, computer, sh
set sh = WScript.CreateObject("WScript.Network")
user = sh.UserName
computer = sh.ComputerName
msgbox "Hello, " & user & vbCrLf & "Logged on from "
& computer
To learn more about WSH, check out MSDN's Scripting Web page.
Want more Win2K tips and tricks? Automatically sign up for our free Windows 2000 Server newsletter, delivered each Tuesday!
SponsoredWhite Papers, Webcasts, and Downloads
- Live Webcast: Reduce Your Costs and Prepare for Tomorrow with BMC CONTROL-M BMC Software
- 2008 IT Salary and Skills Report Global Knowledge
- Eleven Myths about 802.11 Wi-Fi Networks Global Knowledge
Article Categories
- Security
- Security Solutions, IT Locksmith
- Networking and Communications
- E-mail Administration NetNote, Cisco Routers and Switches
- CIO and IT Management
- Project Management, CIO Issues, Strategies that Scale
- Desktops, Laptops & OS
- Windows 2000 Professional, Microsoft Word, Microsoft Excel, Microsoft Access, Windows XP,
- Data Management
- Oracle, SQL Server
- Servers
- Windows NT, Linux NetNote, Windows Server 2003
- Career Development
- Geek Trivia
- Software/Web Development
- Web Development Zone, Visual Basic, .NET






