boat73 has asked for the wisdom of the Perl Monks concerning the following question:

I need to check to see if a domain account is disabled. I have been using Win32API::Net::UserGetInfo to get last logon time and it has flags that should give me what I need but I can't seem to figure out how to access and print the flags. Any guidence on this matter is greatly appreciated. SNIPPET:
Win32API::Net::UserGetInfo($server, $user, $level, \%hash); print "$hash{flags}\n";
just returns "515"

Replies are listed 'Best First'.
Re: check for DISABLED account on win32
by NetWallah (Canon) on Feb 04, 2004 at 17:50 UTC
    Here is some working code that prints user ID's based on another flag value - you can easily modify it to get what you need.

    "When you are faced with a dilemma, might as well make dilemmanade. "