3
3DDELPHI
Unregistered / Unconfirmed
GUEST, unregistred user!
我用以下代码删除一个记录,当我点击时却什么也没发生,请各位大侠指教。
procedure TForm1.Dele1Click (sender:TObject);
begin
if messagedlg('Are you sure to delete this record?',mtConfirmation,[mbYes,mbCancel],0)=mrYes then
begin
//try
table1.Delete;
table1.Post ;
//except
showmessage('Can not dele this record.');
//end;
end;
procedure TForm1.Dele1Click (sender:TObject);
begin
if messagedlg('Are you sure to delete this record?',mtConfirmation,[mbYes,mbCancel],0)=mrYes then
begin
//try
table1.Delete;
table1.Post ;
//except
showmessage('Can not dele this record.');
//end;
end;