Hi,

I'm using Activeds.dll to check for users group and if it doesnt exist then its added to the group. The coding is as follows

Dim sEndUserError As String
Dim myGroup As IADsGroup
Dim myUser As IADsUser
Dim strADSPath As String

sEndUserError = "User " & samAccountName & " was not found on the server " & Domain & "/" & DC & "."
Set myUser = GetObject("WinNT:" & Domain & "/" & samAccountName & ",user")

sEndUserError = "Group " & GroupName & " was not found on the server " & Domain & "."
Set myGroup = GetObject("WinNT:" & Domain & "/" & GroupName & ",group")

If myGroup.IsMember(myUser.ADsPath) Then
IsUserInGroup = True
Else
IsUserInGroup = False
End If

Now the question is without adding reference of Activeds.dll is it possible to use its functionality, by using declare statement for activeds.

What exactly I'm looking for it is to use Declare statement for activeds and how to use that.