in reply to Re: Re: Extracting the name of a logged in user on a remote w2k workstation
in thread Extracting the name of a logged in user on a remote w2k workstation

Does my $username - $ENV{'USERNAME'}; not work for you? It should if %USERNAME% is an environment variable.

Update: D'oh! Managed to skip the 'remote' part of the question entirely...

    --k.


Replies are listed 'Best First'.
Re: Re: Re: Re: Extracting the name of a logged in user on a remote w2k workstation
by Zenistar (Initiate) on Aug 17, 2003 at 16:52 UTC
    Yes that works to grab the USERNAME environment variable from the local machine but what about a remote pc?

    It may be me just being thick and not be able to work something out (must get more sleep), sorry in advance if this is the case.