PowerTip: Use PowerShell to Show Screensaver Info for Logged-on User

Dr Scripto

Summary: Use Windows PowerShell to show screensaver info for a user who is logged on.

Hey, Scripting Guy! Question How can I easily use Windows PowerShell to show screensaver information for the currently logged-on interactive user?

Hey, Scripting Guy! Answer Use WMI to query the Win32_Desktop class, and filter on the logged-on user’s name:

Get-Wmiobject win32_desktop | where name -match $env:USERNAME



Comments are closed. Login to edit/delete your existing comments