|
-
February 17th, 2006, 01:17 AM
#1
Error accessing the OLE registry
Hi Folks,
I get an error message "Error accessing the OLE registry" when I try to
query the Active Directory from my ASP.NET application.
There is no error on local machine and testing machine. But such error
occurs only on production machine.
Does anyone know its resolution?
Code Snippet:
DirectorySearcher directorySearcher = new
System.DirectoryServices.DirectorySearcher(new DirectoryEntry(adServer,
connectionUserID, connectionPassword));
directorySearcher.PropertiesToLoad.Add("memberof");
//Filter the searcher object for passed userID.
directorySearcher.Filter =
"(&(objectClass=user)(objectCategory=user)(samaccountname=" + (userID.Trim())
+ "))";
resultCollection = directorySearcher.FindAll(); ----Error occurs here.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|