como interceptar o pressionamento das teclas ctrl+SHIFT+F10 ?

Delphi

01/05/2013

Olá bom dia!

Desejaria sabe como interceptar o pressionamento das teclas:

Sei que CTRL+F10 é assim: If ((Shift = [ssCtrl]) and (key = vk_F10)) THEN
mas e estas?



CTRL+SHIFT+F10, CTRL+SHIFT+E, CTRL+SHIFT+*


Desde já meus agradecimentos,

ANT.CARLOS/SP
Antonio Jesus

Antonio Jesus

Curtidas 0

Respostas

Wilson Oliveira

Wilson Oliveira

01/05/2013

No evento keydown do form coloque o seguinte código:

procedure TForm1.FormKeyDown(Sender: TObject; var Key: Word;
  Shift: TShiftState);
begin
if Shift = [ssalt, ssCtrl] then
    begin
if key = ord('C') then showmessage('Apertou ctrl + alt + c');
    end;

end;


abcs

GOSTEI 0
Bruno Leandro

Bruno Leandro

01/05/2013

outra forma de fazer seria

procedure TForm1.FormKeyDown(Sender: TObject; var Key: Word;
Shift: TShiftState);
begin
If ((GetKeyState(VK_CONTROL) AND 128)=128) and
((GetKeyState(VK_F5) AND 128)=128) and
((GetKeyState(ord('8')) AND 128)=128)
then
ShowMessage('CTRL+F5+8 Pressionado');
end;

a tabela de vk voce pode pesquisar em
http://delphi.about.com/od/objectpascalide/l/blvkc.htm
GOSTEI 0
POSTAR