473,504 Members | 13,830 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

COMException 0x80072020 with LDAP Query


Hi all,
I've read many times some threads with this problem but no answer is
simple and good enough. Here's my situation:I've developed a web
application with query LDAP which from System.Environment.UserName gets
Name,Department, and so on. It works fine if I access the site with
http://localhost/Site, but if I use
http://Server/Site it gives me the following error:
[COMException (0x80072020): An operations error occurred.
]
System.DirectoryServices.DirectoryEntry.Bind(Boole an throwIfFail)
+610
System.DirectoryServices.DirectoryEntry.Bind() +36
System.DirectoryServices.DirectoryEntry.get_AdsObj ect() +31
System.DirectoryServices.DirectorySearcher.FindAll (Boolean
findMoreThanOne) +73
System.DirectoryServices.DirectorySearcher.FindOne () +42
MasterPage.GetID() in
c:\inetpub\wwwroot\trackingactivity\MasterPage.mas ter.vb:19
MasterPage.Page_Load(Object sender, EventArgs e) in
c:\inetpub\wwwroot\trackingactivity\MasterPage.mas ter.vb:7
System.Web.UI.Control.OnLoad(EventArgs e) +99
System.Web.UI.Control.LoadRecursive() +47
System.Web.UI.Control.LoadRecursive() +131
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
+1061

and the source of the problem is the function:
Result = mySearcher.FindOne()
So, the server is in my domain, I use VS2005, iis settings are:
Enable anonymous access --> NO!!!
Enable Integrated Windows, Digest, Basic Authentication

Please, what can we do to make it work?:)))

Thank you.

--
Tatopitta
------------------------------------------------------------------------
Posted via http://www.codecomments.com
------------------------------------------------------------------------

Dec 3 '05 #1
1 6587
Tatopitta if you are using ASP.NET 2.0
Why don't you make use of the Membership Provider for AD look through :-
http://blogs.msdn.com/guntherb/archi...10/391964.aspx
Its should make your work easier:)
Patrick

"Tatopitta" <Ta**************@mail.codecomments.com> wrote in message
news:Ta**************@mail.codecomments.com...

Hi all,
I've read many times some threads with this problem but no answer is
simple and good enough. Here's my situation:I've developed a web
application with query LDAP which from System.Environment.UserName gets
Name,Department, and so on. It works fine if I access the site with
http://localhost/Site, but if I use
http://Server/Site it gives me the following error:
[COMException (0x80072020): An operations error occurred.
]
System.DirectoryServices.DirectoryEntry.Bind(Boole an throwIfFail)
+610
System.DirectoryServices.DirectoryEntry.Bind() +36
System.DirectoryServices.DirectoryEntry.get_AdsObj ect() +31
System.DirectoryServices.DirectorySearcher.FindAll (Boolean
findMoreThanOne) +73
System.DirectoryServices.DirectorySearcher.FindOne () +42
MasterPage.GetID() in
c:\inetpub\wwwroot\trackingactivity\MasterPage.mas ter.vb:19
MasterPage.Page_Load(Object sender, EventArgs e) in
c:\inetpub\wwwroot\trackingactivity\MasterPage.mas ter.vb:7
System.Web.UI.Control.OnLoad(EventArgs e) +99
System.Web.UI.Control.LoadRecursive() +47
System.Web.UI.Control.LoadRecursive() +131
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
+1061

and the source of the problem is the function:
Result = mySearcher.FindOne()
So, the server is in my domain, I use VS2005, iis settings are:
Enable anonymous access --> NO!!!
Enable Integrated Windows, Digest, Basic Authentication

Please, what can we do to make it work?:)))

Thank you.

--
Tatopitta
------------------------------------------------------------------------
Posted via http://www.codecomments.com
------------------------------------------------------------------------

Dec 4 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
4965
by: jeremy | last post by:
Hello. I have an asp.net application that resides on a non-DC / BDC Sharepoint Server (although it is logged into the domain). The application will perform lookups based on the current user...
4
27920
by: m96 | last post by:
hi, i'm trying to make a query to a ldap server (version v2 or v3 doen't matter) with c#. the query works just fine but the problem is that i can't read the custom attributes/fields, since .net...
1
6023
by: Jody Gelowitz | last post by:
This one should be relatively simple, though I have yet to figure it out. I have an ASP.NET project which uses LDAP authentication to login to the system. When run on our Development or Staging...
3
9866
by: Chad Beckner | last post by:
I am starting to translate some code from ASP to ASP.NET (VB). I was able to query ADS to get a users groups that they belong to, and also query a group and get a list of users. However, I can't...
5
2322
by: Bryan | last post by:
Hello, I have a asp.net app working with directory services on my Windows XP development machine. However when I moved the application over to our production server (Win 2000 Server) it no longer...
0
2547
by: Gerry Sinkiewicz | last post by:
Looking for a bit of software that will accept an LDAP query via port 389 and convert it to an SQL query and return the results to the originating LDAP client. Basically a dialect converter LDAP...
0
1427
by: ssg31415926 | last post by:
I'm using System.DirectoryServices to access a Domino LDAP server. When I get a failed authentication, I usually see this: System.Runtime.InteropServices.COMException 0x8007052E: "Logon failure:...
3
4020
by: RJN | last post by:
Hi I've written a code that queries Windows LDAP server and works fine, but the same doesn't work when querying Solaris LDAP server. DirectoryEntry de = new...
1
11405
by: sasikumarks | last post by:
Hi, Im using the following code to retrieve the user details from the AD server. But when i execute the code,it throws me the error. Please help me in this...
0
7298
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7366
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
7017
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7471
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5610
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5026
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
3176
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
754
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
406
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.