Search Tools Links Login

Disable taskmanager (XP)


Visual Basic 6, or VB Classic

This code temporary disables the taskmanager, works with Windows XP Home ... please vote ...

Original Author: Lee S. Cook

Assumptions

After inputing the code, compile this app... and when a user presses, Alt + CTRL + Del it will display the current application...

Code

Private Sub Form_Load()
  ' Hides the application from the taskmanager
  
  TaskVisible = False
  ' Makes a backup directory for taskmgr.exe
  
  MkDir "C:TASKMANAGER-BACKUP"
  
  ' Makes a backup of taskmgr.exe .
  
  FileCopy "C:WINDOWSSystem32 askmgr.exe", "C:TASKMANAGER-BACKUP askmgr1.exe"
  
  ' Deletes the taskmgr.exe file .
  
  Kill "C:WINDOWSSystem32 askmgr.exe"
  
  ' Copies this application and temporary bypassses it for taskmgr.exe .
  
  FileCopy App.Path & "project1.exe", "C:WINDOWSSystem32 askmgr.exe"
  
End Sub
Private Sub Form_Unload(Cancel As Integer)
  
  ' Copies the original file back to the original location on form unload .
  FileCopy "C:TASKMANAGER-BACKUP askmgr1.exe", "C:WINDOWSSystem32 askmgr.exe"
  
   'Deletes the temporary file
  
  Kill "C:TASKMANAGER-BACKUP askmgr1.exe"
  
  'Deletes the temporary backup folder
  
  RmDir ("C:TASKMANAGER-BACKUP")
  
End Sub

About this post

Posted: 2003-06-01
By: ArchiveBot
Viewed: 96 times

Categories

Visual Basic 6

Attachments

No attachments for this post


Loading Comments ...

Comments

No comments have been added for this post.

You must be logged in to make a comment.