access exchange ldap using adsi

access exchange ldap using adsi

Post by Marcus Schnel » Wed, 08 Dec 1999 04:00:00



hi,

i'm trying to connect to an exchange ldap store using adsi.
when i try to connect using this connect string:

set objMailbox =
GetObject("LDAP://BULLER/o=ComTech/ou=ONLINE_DEV/cn=Recipients/cn=administra
tor")

it works just fine and i can access all the properties.

when i try to connect using this string (so that i can enumerate all
mailboxes):

Set ContainerObj =
GetObject("LDAP://BULLER/o=ComTech/ou=ONLINE_DEV/cn=Recipients")

i get the following error message:

error '80005000'
/jdk/ldap.asp, line 24

any ideas what i'm doing wrong?
please respond via email to

thanks,
marcus

 
 
 

access exchange ldap using adsi

Post by Mirosla » Tue, 21 Dec 1999 04:00:00


Try this using VB and ASP:

Dim ContainerObj, RecipientObj, PropertyObj
Dim MailboxObj

Set ContainerObj =
GetObject("LDAP://ServerName/o=Organization/ou=DomainName/cn=Recipients")
ContainerObj.GetInfo
List1.Clear
For Each RecipientObj In ContainerObj
    RecipientObj.GetInfo
    List1.AddItem ""
    List1.AddItem RecipientObj.Name
    List1.AddItem ""
    PC = RecipientObj.PropertyCount
    For i = 1 To PC
        Set PropertyObj = RecipientObj.Next
        On Error Resume Next
        If InStr(PropertyObj.Name, "Assoc") <> 0 Then Stop
        List1.AddItem PropertyObj.Name & "=" &
CStr(RecipientObj.Get(PropertyObj.Name))
    Next
Next


Quote:> hi,

> i'm trying to connect to an exchange ldap store using adsi.
> when i try to connect using this connect string:

> set objMailbox =

GetObject("LDAP://BULLER/o=ComTech/ou=ONLINE_DEV/cn=Recipients/cn=administra
> tor")

> it works just fine and i can access all the properties.

> when i try to connect using this string (so that i can enumerate all
> mailboxes):

> Set ContainerObj =
> GetObject("LDAP://BULLER/o=ComTech/ou=ONLINE_DEV/cn=Recipients")

> i get the following error message:

> error '80005000'
> /jdk/ldap.asp, line 24

> any ideas what i'm doing wrong?
> please respond via email to

> thanks,
> marcus