Monday, December 31, 2012

PS Quick Tips: Check if screen saver is enabled for the current user

PS D:\> (Get-WmiObject win32_desktop -Filter "Name Like '%$([Environment]::Username)'").ScreenSaverActive

Or:
PS D:\> (Get-ItemProperty -Path 'HKCU:\Control Panel\Desktop').ScreenSaveActive

No comments: