ADSI sample showing how to list all domains in the namespace.
ADSI sample showing how to list all domains in the namespace.
Rate ADSI sample showing how to list all domains in the namespace.
(2(2 Vote))
' This script lists all domains in the namespace
' Goto http://www.activxperts.com/activmonitor and click on ADSI Samples
' for more samples
Sub ListDomains()
Dim objNameSpace
Dim Domain
Set objNameSpace = GetObject("WinNT:")
For Each objDomain In objNameSpace
WScript.Echo "Name: " & objDomain.Name
Next
End Sub
' Main
ListDomains()
WScript.Echo( vbCrlf & "For more samples, goto http://www.activxperts.com/activmonitor and click" )
WScript.Echo( "on ADSI samples" )
ADSI sample showing how to list all domains in the namespace. Comments
No comments yet — be the first to post one!
Post a Comment