Y yuanxianer Unregistered / Unconfirmed GUEST, unregistred user! 2005-12-06 #1 我是要按下delete键后 实现对listbox上记录的删除 应该怎么做? 请指点一二!
Y yuanxianer Unregistered / Unconfirmed GUEST, unregistred user! 2005-12-06 #2 我是要按下delete键后 实现对listbox上记录的删除 应该怎么做? 请指点一二!
D delphi8511 Unregistered / Unconfirmed GUEST, unregistred user! 2005-12-06 #3 procedure Tform1.listbox1KeyDown(Sender: TObject; var Key: Word; Shift: TShiftState); begin if (Key = VK_DELETE) and (listbox1.ItemIndex >= 0) then listbox1.Items.Delete(listbox1.ItemIndex); end;
procedure Tform1.listbox1KeyDown(Sender: TObject; var Key: Word; Shift: TShiftState); begin if (Key = VK_DELETE) and (listbox1.ItemIndex >= 0) then listbox1.Items.Delete(listbox1.ItemIndex); end;
无 无头骑士 Unregistered / Unconfirmed GUEST, unregistred user! 2005-12-06 #6 keydown keyup keypress 这几个里都可做,就是断一下是不是DELTE键
Y yuanxianer Unregistered / Unconfirmed GUEST, unregistred user! 2005-12-06 #8 可以的 我试了一下 呵呵 不好意思 谢谢大家了