I'm not familiar with Dim, but porting sample VB snippets to Perl is usually trivial ... at least enough so that you have a good starting point.
#!perl # Works on my Win2K box running # Perl 5.6.1 (AS's 630 build); # maybe it'll work for you, too! :-) use strict; use warnings; use Win32; use Win32::OLE 'in'; my $group = sprintf "WinNT://%s/Administrators", shift || Win32::NodeName; my $admin = Win32::OLE->GetObject($group) or die( Win32::OLE->LastError, "\n" ); for my $member ( in $admin->members ) { printf "%s (%s)\n", $member->name, $member->class; }
--k.
In reply to Re: using ADSI to recurse the group object for all members of a group.
by Kanji
in thread using ADSI to recurse the group object for all members of a group.
by enigmae
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |