FancyPrairie
Programmer
I have only created one LDAP class retrieving info from Active Directory. We have installed iPlanet on its own server and I need to know the syntax for accessing LDAP.
LDAP Configuration:
Host: MyHost
Port: 477
Agent Port: 4000
Root: ou=abc,dc=ad,dc=mhkk,dc=com
User: cn=Dir Mgr
Password: MyPassword
Administration Port: 12345
The following code produces the error "Can't find table". What am I doing wrong?
LDAP Configuration:
Host: MyHost
Port: 477
Agent Port: 4000
Root: ou=abc,dc=ad,dc=mhkk,dc=com
User: cn=Dir Mgr
Password: MyPassword
Administration Port: 12345
The following code produces the error "Can't find table". What am I doing wrong?
Code:
Sub GetDisplayName()
Dim conn
Dim com
Dim oRecordset
'*******************************
'* Open the connection to AD *
'*******************************
Set conn = CreateObject("ADODB.Connection")
conn.Provider = "ADsDSOObject"
conn.Properties("User ID") = "Dir Mgr"
conn.Properties("Password") = "MyPassword"
conn.Open "LDAP Provider"
Set com = CreateObject("ADODB.Command")
com.ActiveConnection = conn
com.CommandText = "SELECT displayName FROM 'LDAP://MyHost:477/OU=abc,DC=ad,DC=mhkk,DC=com'"
oRecordset = com.Execute
end sub