hamood
asked on
Getting domains, users and groups from Active Dir using LDAP
I am trying to get different domains, their groups and users in groups from active directory server using LDAP. First of all I have to populate the listing of all the groups and their domains from active dir in combo box, now user can select any group from this combo. As soon as user selects this group all the user belonging to this group will be displayed in datagrid with thier attributes like first name, last name, email, address, phone from active dir.
Any help in this regard would be appriciated.
I have tried to used the Active DS Type library in VB6 and successfully implemented the above functionality but i want generic solution using LDAP.
Is there any way to get default domain using Active DS Type library?
Hamood
Any help in this regard would be appriciated.
I have tried to used the Active DS Type library in VB6 and successfully implemented the above functionality but i want generic solution using LDAP.
Is there any way to get default domain using Active DS Type library?
Hamood
https://www.experts-exchange.com/questions/20855763/LDAP-query-in-AD-for-user-profile-path-and-TS-profile-path.html
ASKER
I have checked this but it is not what i needed. I want to get all domains first then after selecting any domain i will get all its groups and when any one selects any groups all its user should be displayed with their attributes in the grid. Actually i need to get displayed all the existing domains, groups and users in active dir but every thing depends on the next one
try something like this to get domains
Set objWinNT = GetObject("WinNT:")
For Each objDomain In objWinNT
Next
Set objWinNT = GetObject("WinNT:")
For Each objDomain In objWinNT
Next
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Set objWinNT = GetObject("WinNT:")
For Each objDomain In objWinNT
Debug.Print objDomain.Name
Next
For Each objDomain In objWinNT
Debug.Print objDomain.Name
Next
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
hes
thanx I have already checked the example at the location and currenty i am using the same technique. But I have to do the things using LDAP because this example uses ADTS library.
mladenovicz
Thanx for the code. I am already using this type of code to get domains but i have to do the things using LDAP. I need a favour in ADTS library for getting default domain of the Active Dir. I would appriciate if you could help me in this regards
Thanx
Hamood
thanx I have already checked the example at the location and currenty i am using the same technique. But I have to do the things using LDAP because this example uses ADTS library.
mladenovicz
Thanx for the code. I am already using this type of code to get domains but i have to do the things using LDAP. I need a favour in ADTS library for getting default domain of the Active Dir. I would appriciate if you could help me in this regards
Thanx
Hamood
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.