How to Disable the Alt + Tab Shortcut

Posted on December 15th, 1999 in System | 1 Comment »

For some reason you may want your program to disable the Alt + Tab keyboard sequence. This procedure will do this for you. This function will have no effect on Windows 9x/NT 4.0/2000/ME/XP/Vista because in these operating systems the Alt + Tab keyboard combination is always active.

!!Note: This code will only work on Windows 9x and ME. This function on Windows NT systems (NT, 2000, XP and Vista) will have NO effect.

uses
  Windows;
...
procedure DisableAltTab;
var
  iTemp: Integer;
begin
  iTemp := 0;
  SystemParametersInfo(SPI_SETFASTTASKSWITCH, 1, @iTemp, 0);
end;

How to Disable the Ctrl + Alt + Delete Shortcut

Posted on December 15th, 1999 in System | No Comments »

For some reason you may want your program to disable the Ctrl + Alt + Delete shortcut. To do so you can use this code.

!!Note: This code will only work on Windows 9x and ME. This function on Windows NT systems (NT, 2000, XP or Vista) will have NO effect.

uses
  Windows;
...
procedure DisableCtrlAltDel;
var
  iTemp: Integer;
begin
  iTemp := 0;
  SystemParametersInfo(SPI_SCREENSAVERRUNNING, 1, @iTemp, 0);
end;