List the User Logged on to a Remote Computer

Returns the user name of the user currently logged on to a remote computer. To use this script, replace atl-ws-01 with the name of the remote computer you want to check. Although

5 Star
Add to favorites
E-mail Twitter Digg Facebook
  • Use this script on workstation
    1 Posts | Last post April 24, 2015
    • The script works fine on my server.
      Is there any way to call this script by a standard user who has no admin rights without getting errors because they are not authorized? I have tried to use a batchfile which calls the the .vbs on the server but get an error.
  • Awesome code
    1 Posts | Last post May 10, 2012
    • I'm trying to edit the code to read from a list of computer names rather than entering one computer name at a time.  I want to run the code to see a lab of computers are in use or not.
  • Suggestion
    2 Posts | Last post November 15, 2011
    • I like this, it's a quick and easy way to discover who the user is, and, if you have only an IP, the computer name as well.
      I made two changes to suit my use, first, to prompt for the Computer name or IP, second, to have the result display both,User and Computer Name.  I frequently need to identify who is downloading large files through our network.  I can easily ID the IP address using our network utility, but it's a chore to look-up, first the computer name, then the user ID from separate lists.  This program helps.
      Try these changes:
      change line 1 to:
      strComputer = inputbox("Enter IP address of the computer for which you want the Computer Name and ID of the Logged on User")
      change the Wscript.Echo... to:
      Wscript.Echo "Logged-on user: " & objComputer.UserName & vbcrlf & "Computer Name: " &
    • Agreed; this is a fantastic way to see who the user is. Great contribution!