Quantcast
Channel: Hey, Scripting Guy! Blog
Viewing all articles
Browse latest Browse all 3333

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

$
0
0

Summary: Use Windows PowerShell to find screensaver information for a user who is currently logged-on.

Hey, Scripting Guy! Question How can I use Windows PowerShell to find screensaver information for a currently logged-on user?

Hey, Scripting Guy! Answer Use WMI, query the Win32_Desktop class, and select the currently logged-on user.

      • In Windows PowerShell 3.0:

Get-CimInstance win32_desktop | where name -eq (whoami)

      • In Windows PowerShell 2.0:

Get-WmiObject win32_desktop | where { $_.name -eq (whoami) } 


Viewing all articles
Browse latest Browse all 3333

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>