I encounter very strange behavior and I don't know if this is intentionally or it is a bug inside scout. (I could understand why this could be a feature, but then I need some work around...)
I have some table inside form. Let suppose that I have two columns Column A and Column B and I have two rows.
------------------------
| Column A | Column B |
------------------------
| 10 | 20 |
------------------------
| 30 | 40 |
------------------------
if I check on client last row like this :
getTField().getTable().getAColumn().getValue(getTField().getTable().getRowCount() -1) = 30
final TFormData formData = new TFormData();
this.exportFormData(formData);
formData.getTable().getAColumn(formData.getTable().getRowCount() - 1) = 30
and this is ok. Now I update last row and delete first one so now it looks like this :
------------------------
| Column A | Column B |
------------------------
| 60 | 40 |
------------------------
now If I try same as before :
// row count = 1
getTField().getTable().getAColumn().getValue(getTField().getTable().getRowCount() -1) = 60
final TFormData formData = new TFormData();
this.exportFormData(formData);
// row count = 2
formData.getTable().getAColumn(formData.getTable().getRowCount() - 1) = 30
formData.getTable().getAColumn(formData.getTable().getRowCount() - 2) = 60
like previous (deleted) row stays inside form data.
I understand that just update already created rows to current value is quicker then replace all rows but shouldn't getRowCount return right number ?