[python-win32] How to say windows run screensaver?
Mark Hammond
skippy.hammond at gmail.com
Sat Jan 24 01:36:36 CET 2009
On 24/01/2009 9:34 AM, Jonathan Rivera wrote:
> Hello all,
>
> i need to run a program to ask for a password, but i need this program
> will be the only accessible window on the screen, so i want to lock
> the screen but no my window.
> i see an example in vb and it say i may to use this:
>
> ' Tell the system a screen saver is running.
> SystemParametersInfo SPI_SCREENSAVERRUNNING, True, prev_value, 0
>
> The problem is that when i use:
>
> win32gui.SystemParametersInfo(win32con.SPI_SCREENSAVERRUNNING, True)
>
> it say: Action 97 is not supported yet
>
> Do you know if are any other way to do the same thing?
Windows documents SPI_SETSCREENSAVERRUNNING as existing on windows 9x
only, so pywin32 hasn't bothered with support for it.
SPI_GETSCREENSAVERRUNNING is supported, but that doesn't sound like what
you need.
You could try using ctypes...
Cheers,
Mark
More information about the python-win32
mailing list