I'm using XE5 and last version of TAdvColumnGrid. If I remove a row using RemoveRows the component remove 2 rows but one is "invisible" so the rowcounter is one more of rows really Painted on the screen.
Is it a bug?
I cannot reproduce this. Please provide some sample source project & detailed steps with which we can reproduce the problem here.
It's easy. Place a TAdvColumnGrid on the form and place 2 buttons to add or remove rows.
Below the onClick buttons events.
At the first click to remove rows (only at the first click) disappear 2 rows, not 1. The rowcounter decreases by 1.
procedure TForm1.BitBtn1Click(Sender: TObject);
begin
AdvColumnGrid1.InsertRows(2,1);
end;
procedure TForm1.BitBtn2Click(Sender: TObject);
begin
AdvColumnGrid1.RemoveRows(AdvColumnGrid1.RowCount,1);
end;
The last row in the grid is grid.RowCount - 1, so, please use a valid row index for grid.RemoveRows()
Sorry, it's a typing error.
It's the same with a number
AdvColumnGrid1.RemoveRows(2,1);
Was retested here with default TAdvColumnGrid on the form and the code:
I tested this little project on other collegues PC with windows7 and winXP with the same result.
Can I send you the exe file just to show you the issue?
Please send source code project by email.