I want to disable start button and alt+tab button using vb.net. Can any one help me. I tried with below coding but not success
Option Explicit
Private Declare Function EnableWindow Lib "user32" _
(ByVal hwnd As Long, ByVal fEnable As Long) As Long
Private Declare Function FindWindow Lib "user32" _
Alias "FindWindowA" (ByVal lpClassName As String, _
ByVal lpWindowName As String) As Long
Private Declare Function FindWindowEx Lib "user32" _
Alias "FindWindowExA" (ByVal hWnd1 As Long, _
ByVal hWnd2 As Long, _
ByVal lpsz1 As String, _
ByVal lpsz2 As String) As Long
Sub StartButton(blnValue As Boolean)
Dim lngHandle As Long
Dim lngStartButton As Long
lngHandle = FindWindow("Shell_TrayWnd", "")
lngStartButton = FindWindowEx(lngHandle, 0, "Button", vbNullString)
If blnValue Then
EnableWindow lngStartButton, 1
Else
EnableWindow lngStartButton, 0
End If
End Sub
Private Sub Command1_Click()
StartButton True
End Sub
Private Sub Command2_Click()
StartButton False
End Sub