Loading |
VBScript |
JavaScript |
Powershell |
Search Options: Determine the Topmost OU For an Active Directory ObjectContent of Determine the Topmost OU For an Active Directory Object.vbsMD5 Hash: C743552F5DE9F8172913A871C9B07294 |
||
Set objSysInfo = CreateObject("ADSystemInfo")
strDN = objSysInfo.UserName arrDN = Split(strDN, ",") For i = UBound(arrDN) to 0 Step -1 If Left(arrDN(i), 3) = "OU=" Then arrOU = Split(arrDN(i), "=") Wscript.Echo arrOU(1) Exit For End If Next | ||
© 2008 - 2013 Boris Toll :: Scripts available: 6.481 :: :: scriptbox.toll.at :: :: powered by www.toll.at :: |