[python-win32] turning monitors off from Python?

Alec Bennett whatyoulookin at yahoo.com
Thu Dec 4 12:01:14 CET 2008


> The article you mention suggests using the desktop window
> handle -- available via GetDesktopWindow (). You might try that?

I have a feeling that was progress, but still no reaction on my monitors. Here's the code including the new clue:

SC_MONITORPOWER = 0xF170
handle = win32gui.GetDesktopWindow()
win32gui.SendMessage(handle, win32con.WM_SYSCOMMAND, SC_MONITORPOWER, 2)            




      


More information about the python-win32 mailing list