>
>Dragan is fairly correct in that this is the behaviour I observe. However, to overcome the problems, I have had to eliminate the delete column and add a delete button. When you click the little delete square, the deleted() method fires, but the actual delete of the record does not occur until after the method completes. I have tried DoDefault(), etc., including deleting the record number passed to the method. What then shows on the grid, when I issue a delete, are 2 deleted records -- the one I deleted and the next or previous record. The behaviour is totally unpredictable (at least to me).
>
>However, I did not use Dragan's exact suggestion, which I will try (I left off the nodefault at the end):
>
>dodefault()
>do_my_code_here
>nodefault
Next try is
if deleted()
recall
else
delete
endif
do_the_other_stuff_here
nodefault
This way we handle the deletion ourselves. Deleting two records instead of one.... hmm, it's kind of contradictory; as if there was some Set Deleted On/Off swapping during the method execution (both the default and/or custom).
Made myself smile for a moment: instead of "if deleted()... recall... else... delete... endif" I started typing "this.deleted=!this.deleted". An unintentional prophecy?