Information générale
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
GETFLDSTATE and SETFLDSTATE
Hi All,
A question about GETFLDSTATE - SETFLDSTATE.
Pessimistic row buffering - editing a record -- cannot use a view with Pessimistic buffering.
On a form I have a textbox control inside a containter. When validation fails (For example, blanking the field when the field is required.) for the control the message displays and the textbox control is returned to its original GOTFOCUS value. Continue to the next field.
Before leaving the textbox validation fires again. I expected it to bypass validation because I have a GETFLDSTATE check. If GETFLDSTATE returns a 1 or a 3 no validation is to occur because the control value did not change.
I am assuming the GETFLDSTATE check fails and validation occurs because the field was once blank then restored so VFP thinks it has been edited. Is this correct?
Secondly, I am thinking that the only way to prevent validation from firing in this scenario is to do a SETFLDSTATE at the restore. Am I correct here as well?
Is there a better way?
Sorry for the long windedness of this post.
Robert
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