how to block windowskeys?

Hi!

I need to disable all windows keys and combinations like strg+alt+entf, strg+Esc.

Any idea how to do this?

Thank you
PhrAtoR
PhrAtoRAsked:
Who is Participating?
 
intheConnect With a Mentor Commented:
this should do it:

procedure keys_off;
var
  L : LongInt;
begin
  SystemParametersInfo (97, Word (True), @L, 0)
end;

procedure keys_on;
var
  L : LongInt;
begin
  SystemParametersInfo (97, Word (False), @L, 0)
end;


call them on form create form destroy etc..
Regards Barry
0
 
intheCommented:
for stopping alt-f4 (closes a window)do:

procedure TForm1.FormKeyDown(Sender: TObject; var Key: Word;
  Shift: TShiftState);
begin
if (ssALT IN Shift) AND(Key = VK_F4) then
KEY:=0;
end;
0
 
PhrAtoRAuthor Commented:
thanks
0
All Courses

From novice to tech pro — start learning today.