J
Jeremy Chapman
I built a page to view user ActiveDirectory object properties. On my
machine it works well, however when I moved the page to a different machine
I get exceptions being thrown when trying to view some of the properties,
such as middleName. The error is 'The directory datatype cannot be
converted to/from a native DS datatype'
The page is set to impersonate, and the app uses windows authentication.
System.Security.Principal.WindowsIdentity.GetCurrent().Name shows that the
user is in fact me. I even tried explicitely impersonating with this code
snippet:
pCurrentIdentity_m = System.Security.Principal.WindowsIdentity.GetCurrent();
pImpersonationContext_m = pCurrentIdentity_m.Impersonate();
Still I get the error?
machine it works well, however when I moved the page to a different machine
I get exceptions being thrown when trying to view some of the properties,
such as middleName. The error is 'The directory datatype cannot be
converted to/from a native DS datatype'
The page is set to impersonate, and the app uses windows authentication.
System.Security.Principal.WindowsIdentity.GetCurrent().Name shows that the
user is in fact me. I even tried explicitely impersonating with this code
snippet:
pCurrentIdentity_m = System.Security.Principal.WindowsIdentity.GetCurrent();
pImpersonationContext_m = pCurrentIdentity_m.Impersonate();
Still I get the error?