Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Stop auto erase when grid textbox accessed
Message
De
10/12/1997 19:26:50
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00064879
Message ID:
00065163
Vues:
28
Thanks to all of you for your help! I tried everyone's advice.

The NODEFAULT solved the problem. The data isn't erased now when the SetFocus puts the cursor into the columns textbox.

John Fish
JF Services
----------------------------------------------------------------------------
>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
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform