ADSI .....this is involved

Results 1 to 2 of 2

Thread: ADSI .....this is involved

  1. #1
    Join Date
    Dec 1969

    Default ADSI .....this is involved

    currently I&#039;m quering a domain using the adsi to do the following:<BR><BR>&#060;%<BR><BR> &#039;--Get the logon user<BR> strLogonUser = request.ServerVariables("LOGON_USER")<BR><BR> &#039;--example of strLogonUser ....akicorp01mkascher<BR><BR><BR> &#039;--Fix the slash<BR> strLogonUser = replace(strLogonUser, "\", "/")<BR> &#039;--example of strLogonUser ....akicorp01/mkascher<BR> <BR><BR> &#039;--Look up the user object in the desired domain<BR> on error resume next<BR> set objUser = GetObject("WinNT://" & strLogonUser & ",User")<BR><BR><BR> &#039;--Get groups for user<BR> for each objGroup In objUser.Groups<BR> strGroups = strGroups & " " & objGroup.Name & "&#124"<BR> next<BR><BR> response.write "groups = " & strGroups <BR> &#039;--example of strGroups .... "GW Reports&#124GW Update&#124"<BR><BR>%&#062;<BR><BR><BR>the above code will give me all the group a specified user is a member of.<BR><BR>-------------------------------------------<BR>WHAT I NEED TO DO INSTEAD!<BR><BR>I need to query the domain not by user account, but by group.<BR>example: GW Reports is a group with the user mkascher in it <BR>I need to grab the this group and all of it&#039;s users in it and check if a specified user is in it. I need the code or an example of this or to know if it is possible <BR><BR><BR>Thank you all!!

  2. #2
    Join Date
    Dec 1969

    Default had ..

    .. some articles on this that I read a while back.<BR><BR>Actually, your best bet is to buy a book on ADSI because the Internet is pretty scarce with articles and tutorials.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts