Board index » Visual Studio » ADSI User object issue
|
HowtoembedawavfiletoaPowerPoint
|
ADSI User object issue
Visual Studio263
I have a couple of questions around the vbscript GetObject command and the resultant User object from Active Directory. I want to be able to get and set some fields but all I get is an error message The fields I cannot get from Active Directory are: pager, mobile, fax, title, department. When I try to get these (along with other fields that DO come through) the page fails with "The Active Directory property cannot be found in the cache" This is not a security issue, as I log in as the domain administrator and it still fails to find these values. here is my code. Can someone help me out here? Set User = GetObject("LDAP://CN=" & userID & ",OU=eCentric,DC=amr,DC=int") WriteLn("CN: " & User.Get("cn")) WriteLn("sAMAccountName: " & User.Get("sAMAccountName")) WriteLn("DisplayName: " & User.Get("DisplayName")) WriteLn("TelephoneNumber: " & User.Get("TelephoneNumber")) WriteLn("TelephonePager: " & User.Get("OtherPager")) WriteLn("TelephoneMobile: " & User.Get("mobile")) WriteLn("FaxNumber: " & User.Get("otherFacsimileTelephoneNumber")) WriteLn("Title: " & User.Get("Title")) WriteLn("Department: " & User.Get("Department")) - |
