The problem is just partially resolved. I've made some new tests (on oct 05
release) and looked over changes you've made in src/ui/frmEditGrid.cpp.
Conclusion: deletion is working correctly only if rows are selected in
ascending or descending order with or without gaps. Selecting rows in an
arbitrary order (ex. 7, 8, 9, 4, 5, 6) won't work.
Method sqlTable::DeleteRows(size_t pos, size_t rows) is working correctly
only on successively rows. So, I see 2 possible solutions (with DeleteRows()
unchanged):
1) order ascending 'delrows' array (wxArrayInt from frmEditGrid::OnDelete -
line 498) and remove lines added in version 1.56
2) call sqlGrid->GetSelectedRows() after every
sqlGrid->DeleteRows(delrows.Item(0), 1);
I'm sorry for insistence, but I want to avoid deletion of wrong lines.
Regards,
Virgil
>> When multiple rows are selected (in Edit Data window) from
>> bottom to top and Delete button is pressed then either the
>> program crashes or wrong rows are deleted.
>>
>
> Thanks. I've committed a fix for this to CVS.
>
> Regards, Dave.