diff options
Diffstat (limited to 'examples')
-rw-r--r-- | examples/gui/gridtest/gridtest.lpr | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/examples/gui/gridtest/gridtest.lpr b/examples/gui/gridtest/gridtest.lpr index 465281b2..f2c0b017 100644 --- a/examples/gui/gridtest/gridtest.lpr +++ b/examples/gui/gridtest/gridtest.lpr @@ -92,7 +92,8 @@ end; procedure TMainForm.btnDelRowClicked(Sender: TObject); begin - stringgrid.DeleteRow(stringgrid.FocusRow); + if StringGrid.RowCount > 0 then + stringgrid.DeleteRow(stringgrid.FocusRow); end; procedure TMainForm.chkDisabledChange(Sender: TObject); |