'*******************************************
' Disable CTRL+ALT+DELETE - by DarKPaiN
'
'w w w . P r o g e n i c . c o m
'*******************************************


'***********PLACE IN MODULE************

Public Const WM_NCLBUTTONDOWN = &HA1
Public Const HTCAPTION = 2
Declare Function ReleaseCapture Lib "user32" () As Long
Declare Function SendMessage Lib "user32" Alias "SendMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, lParam As Any) As Long


'***********PLACE IN FORM************
'Create a Label and call it Title
'Change the caption to Drag Me
'Run it after inserting this code
'and using that label move the form

Private Sub Title_MouseDown(button As Integer, Shift As Integer, X As Single, Y As Single)
    If button <> 1 Then Exit Sub
    Dim ReturnVal&
    ReleaseCapture
    ReturnVal& = SendMessage(hwnd, WM_NCLBUTTONDOWN, HTCAPTION, 0)
End Sub