Scripting Access to WMI

Scripts can access all WMI classes for hardware and software objects. Windows Script Host (WSH) scripts can perform operations on file system objects, manipulate network printers, or change environment variables. You can find a variety of administrator tasks and brief guidance on how to accomplish them in WMI at WMI Tasks for Scripts and Applications. For more information and examples, see the TechNet ScriptCenter Script Repository.

If you are new to scripting or to WMI-specific scripting, see the TechNet ScriptCenter section Getting Started.

With the Scripting API for WMI, you can develop quick, simple scripts or complex Microsoft Visual Basic management applications. Scripting gives you the same capability of getting information or of configuring most objects in an enterprise as you would have through a C++ or C# application. For more information, see Scripting in WMI.

You cannot write a WMI provider in script. For more information, see Providing Data to WMI.

WMI scripts can be written in any scripting language that can interact with ActiveX objects, such as JScript or PerlScript. For more information about using JScript with WMI, see Writing WMI Scripts in JScript.

Active Directory Service Interfaces (ADSI) scripts provides access to Active Directory Domain Services (AD DS) objects. Both WSH and ADSI scripts access objects and allow procedures not available through batch files.

See Also

About WMI
Scripting API for WMI

Send comments about this topic to Microsoft

Build date: 11/3/2009

Tags :


Page view tracker