dectar se shift esta pressionada

Delphi

18/03/2003

como dectar que a tecla shift esta apertada?
seria if dbgrid1.shift = ssShift then
begin
processamento
end?
???
ou como???


Anonymous

Anonymous

Curtidas 0

Respostas

Debora

Debora

18/03/2003

tenta o seguinte:

No evento OnKeyPress

if key = chr(16) then begin
//processamento
end;


GOSTEI 0
Bilouro

Bilouro

18/03/2003

tenta o seguinte: No evento OnKeyPress if key = chr(16) then begin //processamento end;



ValueMeaning

ssShiftThe Shift key is held down.
ssAltThe Alt key is held down.
ssCtrlThe Ctrl key is held down.
ssLeftThe left mouse button is held down.
ssRightThe right mouse button is held down.
ssMiddleThe middle mouse button is held down.
ssDoubleThe mouse was double-clicked.

procedure TForm1.FormKeyDown(Sender: TObject; var Key: Word;
Shift: TShiftState);
begin
if shift =ssShift then
// xxxx
end;


[]´s


GOSTEI 0
Anonymous

Anonymous

18/03/2003

no evento onkeydown
if tbKeyIsDown(VK_SHIFT) then


GOSTEI 0
POSTAR