Private Declare Function SystemParametersInfo Lib "user32" _
Alias "SystemParametersInfoA" (ByVal uiAction As Long, _
ByVal uiParam As Long, pvParam As Any, ByVal fWInIni As _
Long) As Boolean
Private Const SPI_GETSCREENSAVEACTIVE As Long = &H10
Private Const SPI_GETSCREENSAVERRUNNING As Long = &H72
Private Sub Timer1_Timer()
Dim is_running As Boolean
SystemParametersInfo SPI_GETSCREENSAVERRUNNING, 0, _
is_running, False
If is_running Then Beep
End Sub
|