Just a quick one I found very helpful although I only needed it twice in my life. Well and it doesn’t change that often, but you never know when you may need to know the LDAP version in your environment.

Set objRootDSE = GetObject("LDAP://RootDSE")
For Each strVersion In objRootDSE.Get("SupportedLDAPVersion")
    Wscript.Echo "LDAP Version: " & strVersion
Next

But, no need for doing it the old fashioned way. In Powershell, this is just as simple as one cmdlet.

Get-ADRootDSE
Advertisements