Chapter 12. Scripting Windows

Windows Automation Methods 351

Writing WSH Scripts 356

Using Windows Management Instrumentation (WMI) 365

Summary 371

The usual way to add a printer, create a new user, or perform any administrative task in Microsoft Windows is to use a graphical tool such as a Microsoft Management Console (MMC) snap-in or a wizard. However, even simple tasks can quickly get laborious and time-consuming when performed multiple times. For example, you can easily spend five minutes connecting a new printer and installing drivers on the print server, and then spend two hours manually connecting each client in a domain to the new printer using the Add Printer Wizard.

Unfortunately, automating such tasks in Windows has historically been ...

Get Microsoft® Windows Server 2003: Administrator’s Companion now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.