Hi George,
I tried the following code to test the enable/disable of the sceen saver. The last call to SystemParameterInfo returns .F. and the screen saver state is not changed.
What did I do wrong?
Thanks,
Ray
#DEFINE GETSCREENSAVEACTIVE 16
#DEFINE SETSCREENSAVER 17
DECLARE SHORT SystemParametersInfo IN WIN32API ;
INTEGER uiAction, SHORT uiParam, ;
INTEGER @pvParam, INTEGER fWinIni
lnvparm = 0
? (SystemParametersInfo(GETSCREENSAVEACTIVE,0, @lnvparm,0) # 0)
IF lnvparm = 0
liniparm = 1 && Enable Screen saver
? "Screen saver is being enabled"
ELSE
liniparm = 0 && Disable Screen Saver
? "Screen saver is being disabled"
ENDIF
? (SystemParametersInfo(SETSCREENSAVER,liniparm,0,0) # 0)
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only