Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Detect changes to a cell grid
Message
 
À
02/08/2000 09:23:58
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00399549
Message ID:
00399879
Vues:
11
CurVal() tells you the value in the field on disk (that is it reflects changes any other users may have made while you were working on the record)

OldVal() tells you what your field started with in your buffer (that is what the value was before you made any changes to it)

Alias.FieldName refers to the field in your buffer (that is the value it has now in the buffer including the changes you may have made)

GetFldState() tells you if you have hcanged the field in your buffer or not.

Example:

Table named MyTable and field named MyField with a vlaue of "ABC"
* Open the table
USE MyTable
* Set buffering on
CURSORSETPROP("Buffering",5,"MyTable")

? MyTable.MyField  && Shows the ABC

REPLACE MyField WITH "XYZ"

? MyTable.MyField  && Shows XYZ
? OldVal("MyTable.MyField")  && Shows ABC

* Some other user changes MyField to MNO

? MyTable.MyField  && Shows XYZ
? OldVal("MyTable.MyField") && Shows ABC
? CurVal("MyTable.MyField")  && Shows MNO

? GetFldState("MyTable.MyField") && Shows 2 Field has been changed
? GetFldState("MyTable.SomeOtherField") && Shows 1 field has not changed
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform