views:

61

answers:

1

I'm trying to convert the distinguishedName of a Domain into the address for the domain and am wondering if the order is strict. They all seem to be (after using the Active Directory explorer http://technet.microsoft.com/en-us/sysinternals/bb963907.aspx to explore ActiveDirectory...). I just haven't found anywhere which states the order is strict...

so, I'm hoping that:

DC=safety,DC=company,DC=com

is always equal to

safety.company.com

or could safety.company.com be stored in ActiveDirectory with any of the following etc:

DC=com,DC=company,DC=safety
DC=company,DC=com,DC=safety

Ultimately when passed the DC=...string, I want to be able to do the following to store the address:

Dim ADPath As String = "DC=safety,DC=company,DC=com"
Dim DomainAddress As String = ADPath.Replace(",DC=",".").Replace("DC=","")
A: 

Not the easiest text to read (for me anyway) but this MSDN page does describe that the path from left to right is a hierarchical path that uniquely describes the object.

"A DN is a sequence of relative distinguished names (RDN) connected by commas."

source: http://msdn.microsoft.com/en-us/library/aa366101%28VS.85%29.aspx

davidsleeps