How can I use vbs to remotely (or locally) determine what username is
currently logged in at the desktop of a workstation and also how long that
username has been logged in? I don't need the code necessarily, just a place
to look.
Thanks

Re: Current logged on user and session time. by Scott

Scott
Thu Dec 30 15:10:20 CST 2004

Look at the documentation for WMI, specifically the Win32_ComputerSystem
class, for the username property.

Offhand I don't know about the login time, other than checking AD for the
account's lastLogin property. But that's not always entirely accurate for
various network-related reasons. You could add an line in the user's login
script to write their login time to a file on the workstation or to a file
server (or even insert it into a database), then read that value later.

--
Scott Fenstermacher
Network Engineer
Levi, Ray and Shoup, INC

"Tim Newman" <Tim.Newman@kmcnetwork.org> wrote in message
news:O41vSpo7EHA.1300@TK2MSFTNGP14.phx.gbl...
> How can I use vbs to remotely (or locally) determine what username is
> currently logged in at the desktop of a workstation and also how long that
> username has been logged in? I don't need the code necessarily, just a
> place
> to look.
> Thanks