Finding Logged-On User

Share |

Subscribe to Feed

PowerShell eBook
Sign up for
Your PowerTip of the Day:

Powershell Plus

13 Free SQL Tools from Idera

Free Ebook: Mastering Powershell

There is a helpful console application called quser.exe which will tell you who is logged on to a machine. The executable returns plain text, but with the help of a little regular expression, this text can be converted to CSV and then imported into PowerShell.

So this will give you rich objects for all users currently logged on to your machine:

Twitter This Tip! ReTweet this Tip!

Posted Jan 14 2014, 06:00 AM by ps1


farisnt wrote re: Finding Logged-On User
on 01-14-2014 11:14 AM

Powershell can not start the application unless I write the full path, that is strange


Sachin Nair wrote re: Finding Logged-On User
on 01-15-2014 4:47 AM

This is super useful. I always struggled with a way to format the output for commands like quser qwinsta etc. This is so easy. Thanks a ton !

LuckyGuy wrote re: Finding Logged-On User
on 01-15-2014 12:30 PM

@farisnt I noticed the same thing while trying the command from my workstation. However, running it from a server worked fine.Perhaps a server configuration has quser located in a different directory.

Copyright 2012 All rights reserved.