Re: How to eliminate the Append and Delete on DBGrid

Posted by Andreas S. on May 15, 2003

In Reply to: How to eliminate the Append and Delete on DBGrid posted by sam sgling07 on April 12, 2003

: I would like to control the DBGrid that unable it to Append and delete any records shown on the DBGrid.
: Someone please help me on this if you know about it.

Use the Events BeforeInsert and BeforeDelete of your Dataset:

procedure TForm1.Table1BeforeDelete(DataSet: TDataSet);
begin
  Abort;  // raise a silent exception
end; 
 

Find related articles

Search for:  DBGrid   Dataset  Table


Delphi Forum :: Tutorials :: Source code :: Tips