powershell (Add-Type '[DllImport(\"user32.dll\")]^public static extern int PostMessage(int hWnd, int hMsg, int wParam, int lParam);' -Name a -Pas)::PostMessage(-1,0x0112,0xF170,2) |
Hmm, during times when listening to some audio on the computer and turning the screen off, it works and isn't turned back on.
Hopefully there are ways to turn the screen back on only when there is certain event - in this case a mouse click.
Hmm, during times when listening to some audio on the computer and turning the screen off, it works and isn't turned back on. Hopefully there are ways to turn the screen back on only when there is certain event - in this case a mouse click.
Did you ever find a solution to this? Want to do the same thing. Thanks!
This shuts off the screen and locks the desktop. Would be nice if there was a way to just shutoff the screen.
AFAIK, the Windows OS will wake the screen on any KB or mouse event, and will bring you to the unlock screen (or desktop if security is disabled).
Is this still working for you guys? for me the screen turns off then immediatley turns back on - no mouse or keyboard movements (by me)...
@Shazib
Can confirm that it works for me with Windows 10 Pro 22H2.
First of all thanks to EugeneLoy and unknown for me the author of the command :-)
Today 2.6.2023 - it works for me. Conditions - Win10 22H2. Two monitors. Both displays are turned off one time.
Is this still working for you guys? for me the screen turns off then immediatley turns back on - no mouse or keyboard movements (by me)...
Cheers.
FYI I've discovered that this doesn't play nice with my monitor that supports DDC/CI control. https://github.com/xanderfrangos/twinkle-tray/ works though.
Thank you
I am not aware of a windows setting for that. Any activity will bring it back. If there is YouTube video playing in the background, it can bring the screen back on too. So, if you want to just listen, open another tab in your browser so that the YouTube video is not in the active tab.