Results 1 to 2 of 2

Thread: Stand By

  1. #1

    Thread Starter
    New Member
    Join Date
    Sep 2002
    Location
    india
    Posts
    2

    Wink Stand By

    j.shyam

  2. #2
    Hyperactive Member Wak's Avatar
    Join Date
    Nov 2000
    Location
    Brisbane, Queensland
    Posts
    298

    ...

    Code:
    Option explicit
    
    Private Declare Function ExitWindows Lib "user32" Alias "ExitWindows" (ByVal dwReserved As Long, ByVal uReturnCode As Long) As Long
    
    Const EWX_POWEROFF = &H00000008
    Const EWX_LOGOFF = 0
    Const EWX_SHUTDOWN = 1
    Const EWX_REBOOT = 2
    Const EWX_FORCE = 4
    
    Private Sub Form_Load()
    dim RetVal as Long
    RetVal = ExitWindows(EWX_POWEROFF, 0)
    
    If RetVal = 0 Then ExitWindows EWX_POWEROFF or EWX_FORCE, 0
    
    End Sub

    Yes siiiiir!
    Visual Basic 6.0 Enterprise
    Visual C++ 6.0 Professional

    Wak

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width