Apart from my other post unable to get IIS to run the perl script with admin permissions.
I decided to do some testing running script locally.
The script runs without the permissions error, I issue the add member to group code...
and when I check the group sure enough the user has been added.
However, when i then try to display the members of the group I get the following error...
taken from this link ...
any ideas why this won't work?
if I just get the top level .i.e. my $objGroup = Win32::OLE->GetObject("WinNT://$server/"); and loop displaying hash key 'Name' I get a list of all the user accounts and groups?
I need some help!
"In complete darkness we are all the same, only our knowledge and wisdom separates us, don't let your eyes deceive you.
I decided to do some testing running script locally.
The script runs without the permissions error, I issue the add member to group code...
Code:
# Get group Object
my $objGroup = Win32::OLE->GetObject("WinNT://$server/" . $group) or die "Unable to get group object";
# Add a member
$objGroup->Add("WinNT://$server/" . $user);
and when I check the group sure enough the user has been added.
However, when i then try to display the members of the group I get the following error...
using this code...[Tue Feb 13 14:45:33 2007] ldap_test.pl: Win32::OLE(0.1707) error 0x80020003: "M
ember not found"
Code:
print "Members of ", $objGroup->Name . ":\n";
foreach my $objMember (in $objGroup->Members) {
print $objMember->Name,"\n";
}
any ideas why this won't work?
if I just get the top level .i.e. my $objGroup = Win32::OLE->GetObject("WinNT://$server/"); and loop displaying hash key 'Name' I get a list of all the user accounts and groups?
I need some help!
"In complete darkness we are all the same, only our knowledge and wisdom separates us, don't let your eyes deceive you.