Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Determining changed values in fields
Message
De
29/08/2003 15:19:33
 
 
À
29/08/2003 12:24:33
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00824599
Message ID:
00824681
Vues:
23
Thanks Hilmar - figured out what I was doing wrong. Yup that is the way to go.
Gaylen

>>I have a form with many many fields. I use table buffering and tableupdate to commit the changes if a field value has been changed. Using getfldstate() I can determine if a field has had activity I need to determine which field has changed and the previous and new values are for use later.
>>
>>I am thinking of storing the old value in a form property from gotfocus() and new value in another form property from lostfocus() and then compare the results and storing in a table.
>>
>>I am looking for a more elegant way to do this without manually creating all those form properties.
>>
>>Thanks in advance for any suggestions.
>>Gaylen
>
>GetFldState() will tell you whether a field or fields has / have changed - even if it reverts to its old value.
>
>OldVal("MyField") will give you the value before the modification.
>
>CurVal("MyField") will fetch the value from disk again (this is in case another user made a change).
>
>Usually, you would compare MyField with OldVal("MyField"). For instance, I use this in triggers, to update another table.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform