Working with IADsADSystemInfo

In this section, you will use the IADsADSystemInfo interface to obtain data about the local computer. The IADsADSystemInfo interface is implemented for access to the ADSystemInfo class. Because this class resides in the adsldp.dll file, which is part of ADSI, it is present on Microsoft Windows Server 2003, Windows XP, and even Windows 2000. To use IADsADSystemInfo, you need to hook it by creating an instance of the ADSystemInfo class. This process is actually simple—you use the CreateObject command. Table 16-1 summarizes the nine properties exposed by IADsADSystemInfo.

Table 16-1. Properties Exposed by IADsADSystemInfo

Property

Meaning

ComputerName

Retrieves the distinguished name of the local computer

DomainDNSName

Retrieves ...

Get Microsoft® Windows® Scripting Self-Paced Learning Guide 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.