Home Page Free Software CCTV Products CCTV Samples Local Services Offshore Services Contact Us

Computer Repair
Tel: 242-364-9183
Nassau, Bahamas
Bahamas Video Surveillance . Bahamas CCTV . Bahamas Infrared . Bahamas Digital Video . Bahamas Remote Video . Bahamas Burglar Alarm . Bahamas Technician
Bahamas Real Estate
Bahamas Yellow Pages


Free Software:


We Recommend:
MediaFire - Free File Hosting Made Simple
Follow us on:
Twitter Twitter
Disable ScreenSaver
Disable the Windows ScreenSaver.
           
'Author: Waty Thierry
'Origin: http://www.geocities.com/ResearchTriangle/6311/
'Purpose: Activate/Deactivate the Screen Saver
'Version: VB4+

Option Explicit

Private Const SPI_SETSCREENSAVEACTIVE = 17
Private Const SPIF_UPDATEINIFILE = &H1
Private Const SPIF_SENDWININICHANGE = &H2

Private Declare Function SystemParametersInfo Lib "user32" _
Alias "SystemParametersInfoA" (ByVal uAction As Long, ByVal _
uParam As Long, ByVal lpvParam As Long, ByVal fuWinIni As _
Long) As Long

Public Function ToggleScreenSaverActive(Active As Boolean) As Boolean
    'To Activate Screen Saver, set active to true
    'to deactivate, set active to false
    Dim lActiveFlag As Long
    Dim retval As Long
    lActiveFlag = IIf(Active, 1, 0)
    retval = SystemParametersInfo(SPI_SETSCREENSAVEACTIVE, _
       lActiveFlag, 0, 0)
    ToggleScreenSaverActive = retval > 0
End Function

Private Sub Form_Load()
 ToggleScreenSaverActive False
End Sub

Private Sub Form_Unload(Cancel As Integer)
 ToggleScreenSaverActive True
End Sub

      

 

Bahamas CCTV . Bahamas DVR . Bahamas Camera . Bahamas Video . Bahamas Computer Repair . Bahamas Software . Bahamas Business . Bahamas Real Estate
Copyright (c) 2001/2010 BahamasSecurity.com