If you need to disable keyboard delete operation inside a DBGrid you'll need to disable the CTRL+DELETE key press.
~~~~~~~~~~
procedure Form1.DBGrid1KeyDown
(Sender: TObject; var Key: Word; Shift:TShiftState) ;
begin
if (Shift = [ssCtrl]) and (Key = VK_DELETE) then
Key := 0; {ignore}
end;
~~~~~~~~~~
~~~~~~~~~~
procedure Form1.DBGrid1KeyDown
(Sender: TObject; var Key: Word; Shift:TShiftState) ;
begin
if (Shift = [ssCtrl]) and (Key = VK_DELETE) then
Key := 0; {ignore}
end;
~~~~~~~~~~
Δεν υπάρχουν σχόλια:
Δημοσίευση σχολίου