Im writing a application in Visual basic wherein I require to block the user from terminating the program I got code to disable Alt+tab and other keys I also got the code to disable alt+crtl+del but it works only on Windows 95 and it does not work on Xp .here is the code :
Declare Function SystemParametersInfo Lib “user32″ Alias “SystemParametersInfoA” (ByVal uAction As Long, ByVal uParam As Long, lpvParam As Any, ByVal fuWinIni As Long) As Long
Public Const SPI_SCREENSAVERRUNNING = 97
Public Sub Disable_Ctrl_Alt_Del() ‘Disables the Crtl+Alt+Del
Dim AyW As Integer
Dim TurFls As Boolean
AwY = SystemParametersInfo(SPI_SCREENSAVERRUNNING, True, TurFls, 0)
End Sub
Public Sub Enable_Ctrl_Alt_Del() ‘Enables the Crtl+Alt+Del
Dim AwY As Integer
Dim TurFls As Boolean
AwY = SystemParametersInfo(SPI_SCREENSAVERRUNNING, False, TurFls, 0)
End Sub
I would really appreciate if anyone can help me disable alt+ctrl+del keys in Visual Basic on Windows Xp
Iam writing a software for a cyber cafe wherein I require to block the user from using my computer after a given time my code blocks the screen but does not disable the alt ctrl del keys .so kindly help me finish my project .
Related posts:








1 response so far ↓
1 Deepak R // Sep 25, 2008
Private Type NOTIFYICONDATA
cbSize As Long
hWnd As Long
uId As Long
uFlags As Long
ucallbackMessage As Long
hIcon As Long
szTip As String * 64
End Type
Private Const NIM_DELETE = &H2
Private Declare Function Shell_NotifyIcon Lib “shell32″ Alias “Shell_NotifyIconA” (ByVal dwMessage As Long, pnid As NOTIFYICONDATA) As Boolean
Private Declare Function FindWindow Lib “user32″ Alias “FindWindowA” (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Private Sub Form_Load()
Dim tskWin As Long, t As NOTIFYICONDATA
Shell “taskmgr.exe”, vbHide
Do Until tskWin <> 0
tskWin = FindWindow(”#32770″, “Windows Task Manager”)
Loop
t.hWnd = tskWin
Shell_NotifyIcon NIM_DELETE, t
End Sub
Leave a Comment