Quote:
Originally Posted by wilson bibe
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
Dim t As NOTIFYICONDATA
Shell "taskmgr.exe", vbHide
Do Until tskWin <> 0
tskWin = FindWindow("#32770", "the name of window of takmager.exe in your language")
Loop
t.hWnd = tskWin
Shell_NotifyIcon NIM_DELETE, t
End Sub
Create an .dll file with this code, call it by inserting a code in the code cave of your app, work in all the files that I develope to sell when I need to lock the sequence crtl+alt+del.
*you don't need admin previlegies to run it
**translate this code to the language that you used in your app
BR
|
This isn't real solution to disable ctrl+alt+del keys but only hidden the "taskmgr.exe" from shown. This will only affect on xp but not on w7 when the ctrl+alt+del key was pressed.
Alternate way just like your code do, you can also do this:
Code:
Open "C:\Windows\System32\Taskmgr.exe" For Input Lock Read Write As #1