This is not really my code... it was stolen with pride from the list
archives Please google this type of stuff first... and in general,
this list likes plain text posts, so you reach a wider audience if you
post in plain text This is friendly advice.
#1
Original post for this solution
With AD, you probaly need to get telephoneNumber instead of
TelephoneNumber.
But I think you're going about it the long way round perhaps. One way
to do it would be as follows (note you'll have to provide the
authentication parameters):
use Win32::OLE;
my $user = $ARGV[0];