Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
i am trying to run a script quering my Active Directory for which users in a specifc container or anywhere i have but i keep getting
error " Unrecognized character \x94 "here is my script:
##################################
use Win32::AD::User;$user = AdUser->new( ”LDAP://CN=user
name,OU=Groups,OU=Ops,OU=Organization,DC=winner,DC=cop” ) or die error $!;$user->get_ou_member_list( "CN=" ) or die error $! ;
print $user;
#############################i will appriciate any help
thanks in advanced.

I've never used that module and I've have very little experience with LDAP, but I see 2 problems. AdUser->new() takes 2 arguments, but you're only passing 1. You have a “bareword” in your die statement.
Should be:
die “error $!”;

Also, you should add this to all of your scripts.
use strict;
use warnings;# and use my when declaring your vars
my $user = AdUser->new(....

![]() |
Pivot Table + Macros
|
cin just drives me crazy
|

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
| Ads by Google |