Information générale
Catégorie:
Programmation Orientée Object
Titre:
HELP !! How do I avoid doing Valid ?
I am writing my 1st application in FoxPro and need some help.
I do a seek in the "valid" event of a text box to make sure it exists in a table. If not, I show an error message ("this value does not exist!") and return .f., else I return .t.
I've created command buttons to "Save" and "Cancel".
If the "Cancel" button is clicked, the valid event causes the error message "this value does not exist" to pop up and I cannot get out of the test box until a valid value has been entered.
How can I avoid this ? Is there maybe a way that I can test if the "Cancel" button has been clicked so that I can use an IF statement in my Valid event to only execute if "Cancel" has NOT been selected ? I've tried to set a flag in the click event of the Cancel command button but that doesn't work !
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement