IADsComputer Interface

Inherited from

IADs

IDispatch

IUnknown

Applies to Objects
Computer

This is the primary Interface of the Computer object. You can use this interface to get properties of computers, like operating system, processor type, and so on.

Property/Method

Description

Access

Gets the Security object for managing permissions for the Computer

Addresses

Gets the IP Address of the computer

ComputerID

Gets the globally unique identifier (Ethernet-ID) assigned to each computer

Department

Department to which this computer belongs

Description

Gets and sets the Description of a computer

Division

Gets and sets the Division to which the computer belongs

IsValid

Returns TRUE if RelativeName is a valid Name of the given Class type

Location

Gets and sets the physical location of this computer

MemorySize

Gets the size of RAM in MBs

Model

Gets the make or model of a computer

NetAddress

Gets the binding information for the Computer

OperatingSystem

Gets the name of the operating system used on a computer

OperatingSystemVersion

Gets the operating system version number

Owner

Gets the name of the person that typically uses a computer and has a license to run the installed software

PrimaryUser

Gets and sets the contact person for this computer

Processor

Gets the type of processor

ProcessorCount

Gets the number of processors

Role

Gets the role of a computer - whether it is a workstation, server, domain controller, and so on

Site

Gets the globally unique identifier identifying the site a computer is installed in. A site represents a physical region of good connectivity in a network

StorageCapacity

Gets the size of disk space in MBs

Example
This example demonstrates the use of IADsComputer Properties and Methods.

Dim Computer As IADsComputer
'Bind to the known NT Computer object.
'MSFT is the domain name and Moon is the name of a computer in MSFT.
Set Computer = GetObject("NTDS://MSFT/Moon")
'Debug.Print to print the name, Description etc. to the debug window.
'you can use the Name property as IADsComputer is derived from IADs.
'assume that the current value of Description is "Old Description"
Debug.Print Computer.Name
Debug.Print Computer.Description 'prints Old Description
Debug.Print Computer.Owner
Debug.Print Computer.OperatingSystem
Debug.Print Computer.ComputerID
'Change the Description of the Computer.
'WARNING: This will change the value of the Description property!!!
Computer.Description = "New Description"
Debug.Print Computer.Description 'prints New Description
Computer.GetInfo
Debug.Print Computer.Description 'prints Old Description
Computer.Description = "New Description"
'Call SetInfo to commit the changes to the network.
Computer.SetInfo
'Call GetInfo to get the new values.
Computer.GetInfo
'Display Description.
Debug.Print Computer.Description
'prints New Description