#DEFINE SPI_GETSCREENSAVEACTIVE 16 #DEFINE SPI_SETSCREENSAVEACTIVE 17 * Find out whether or not the screen saver is active DECLARE SHORT SystemParametersInfo IN Win32API; INTEGER uiAction, SHORT uiParam,; INTEGER @pvParam, INTEGER fWinIni lnvparm = 0 STORE .F. TO llresult, llactive llresult = (SystemParametersInfo(SPI_GETSCREENSAVEACTIVE, 0, @lnvparm, 0) # 0) IF llresult llactive = (lnvparm # 0) ENDIF IF llactive * Turn if off DECLARE SHORT SystemParametersInfo IN Win32API; INTEGER uiAction, SHORT uiParam,; INTEGER pvParam, INTEGER fWinIni = SystemParametersInfo(SPI_SETSCREENSAVEACTIVE, 0, 0, 0) ENDIF * Processing code here IF llactive * Turn it back on = SystemParametersInfo(SPI_SETSCREENSAVEACTIVE, 1, 0, 0) ENDIFPlease note the differences between the two declarations. These are necessary.