Hi,
i am new on VB .net and i want to list all Active Directory Users in a WebInterface.
It is no problem in Windows Applications to list users, but in Web Application i allay get the following error
Server Error in '/IP-Phone-Admin' Application.
--------------------------------------------------------------------------------
The specified domain either does not exist or could not be contacted
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Runtime.InteropServices.COMException: The specified domain either does not exist or could not be contacted
Source Error:
Line 33: Dim result As System.DirectoryServices.SearchResult
Line 34: mySearcher.Filter = "(ObjectClass=user)"
Line 35: For Each result In mySearcher.FindAll()
Line 36: DropDown.Items.Add(result.GetDirectoryEntry().Path )
Line 37: Next
Source File: C:\Inetpub\wwwroot\IP-Phone-Admin\WebForm1.aspx.vb Line: 35
Stack Trace:
[COMException (0x8007054b): The specified domain either does not exist or could not be contacted]
System.DirectoryServices.DirectoryEntry.Bind(Boole an throwIfFail)
System.DirectoryServices.DirectoryEntry.Bind()
System.DirectoryServices.DirectoryEntry.get_AdsObj ect()
System.DirectoryServices.DirectorySearcher.FindAll (Boolean findMoreThanOne)
System.DirectoryServices.DirectorySearcher.FindAll ()
IP_Phone_Admin.WebForm1.Page_Load(Object sender, EventArgs e) in C:\Inetpub\wwwroot\IP-Phone-Admin\WebForm1.aspx.vb:35
System.Web.UI.Control.OnLoad(EventArgs e)
System.Web.UI.Control.LoadRecursive()
System.Web.UI.Page.ProcessRequestMain()
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573
I hope that anybody can help me
thanx
mario