John,
Your problem is that the keystroke is still being processed after your code and that is overwriting the contents of the next textbox. You need to adjust your keypress code so that it clears the keystroke after the delete;
IF Whatever
DELETE
thisform.grid_whatever.column3.setfocus()
thisform.refresh()
NODEFAULT && eat the keystroke
ENDIF
Jimb
>I have it set up so that when a certain KeyPress occurs while the user is in any row of a grid this code is performed ...
>
> Delete
> thisform.grid_yell_card.Column3.setfocus
> thisform.refresh
>
>I have a filter on the grids table to not show deleted records.
>
>My problem is that everything works fine after the user chooses to delete the record ... the line they are on disappears like it should after it is marked for deletion in the code above, but when the cursor moves to any remaining line in the grid, the data in the column textbox it goes onto get erased and the cursor sits at the beginning of the now empty, textbox. I don't want it to erase the data contents of the textbox it moves into.
>
>I have tried turning SelectOnEntry on and off for the column's textbox properties, but this problem still continues. I even tried changing the above Setfocus line so the focus will go to a different columns textbox and the same erasure occurs. How can I keep a columns textbox contents from being erased when the Setfocus puts the cursor into it.
>
>John Fish
>JF Services