Asit Sinha
New member
- Joined
- Aug 4, 2008
- Messages
- 1
- Programming Experience
- 3-5
Respected sir
I have a dialog box. In dialog box show domain users and groups.
But our requirements is if there are several domain and in each domain have users/Groups.
Then how I fetch this information.
In our code I am using active directory code is
After that fetch the groups with this code.
This code is work perfectley.
But in case of multi domain is not work.So please suggest me how I fetch information in case of multi-domain and multi-domain user and group.
Please immediate reply me.
Thank
Asit Sinha
I have a dialog box. In dialog box show domain users and groups.
But our requirements is if there are several domain and in each domain have users/Groups.
Then how I fetch this information.
In our code I am using active directory code is
VB.NET:
Utility.GetDirectoryInfo("LDAP://ABC", "Administrator", "Admin")
After that fetch the groups with this code.
VB.NET:
Public Function getAllGroups() As TreeNode
Dim WinID As System.Security.Principal.WindowsIdentity
WinID = Security.Principal.WindowsIdentity.GetCurrent()
Dim User As New System.Security.Principal.WindowsPrincipal(WinID)
Try
Dim _AllGroups As ArrayList
Dim _AdGroup As ADGroup
_AllGroups = ADManager.Instance.LoadAllGroups
Dim i As Short = 0
For i = 0 To _AllGroups.Count - 1
_AdGroup = _AllGroups(i)
GroupNode.Nodes.Add(New TreeNode(_AdGroup.Name, 3, 3))
Next
Catch ex As Exception
Throw ex
End Try
Return GroupNode
End Function
But in case of multi domain is not work.So please suggest me how I fetch information in case of multi-domain and multi-domain user and group.
Please immediate reply me.
Thank
Asit Sinha