Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

making a connection to AD

Status
Not open for further replies.

klaforce

Programmer
Mar 25, 2005
124
US
I am trying to create a password reset utility for my company, and I want to use .Net to do this. Right now I am just trying to get a connection to AD. I keep getting the following error
"System.Runtime.InteropServices.COMException: The specified domain either does not exist or could not be contacted"

Here is code that I am using.
Code:
Dim objOUPath As String = "LDAP://strAdPath"
Dim objOU As New System.DirectoryServices.DirectoryEntry(objOUPath, "DOMAINUSER","PASSWORD")
If System.DirectoryServices.DirectoryEntry.Exists(objOUPath) Then
enumberErrorLabel.Text = "pass"
Else
locationErrorLabel.Text = "fail"
End If

I have tried turning off anonymous authenication, changing the machine.config file, editing the web.config file, making sure my domain account has permissions to my web app directory... I am out of ideas, and out of research. Any ideas?


Keith


The most likely way for the world to be destroyed, most experts agree, is by accident. That's where we come in; we're computer professionals. We cause accidents.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top