Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
GO EOF() Does Not Work
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00117869
Message ID:
00118036
Vues:
24
>----------
>
>Sounds like a good solution, but I'll have to do some studying on buffering, tableupdate, and tablerevert. This is another part of VFP that I haven't used. Can you give me some guidelines as to how to go about using these? Thanks, CH.

Chuck,

Sure, here's an easy way to get used to them. Set the buffermodeoverride property of your tables to 5 - Optimistic Table Buffering and in your Save button do;
IF TableUpdate( 0, .F., "<AliasName>")
   * Update failed
   THIS.cmdRevert.Click()
ENDIF
For each alias that is open. IN the revert button's click;
TableRevert(.T.,"<The alias name>")
...
<PRE>

For each alias in the form. 

You make this more generic with the buttons by using a form class that has  DoSave and DoRevert methods.  Thennyou write the code in the form's methods and call those from the buttons. In this case the Save button's click becomes;

<PRE>
IF NOT THISFORM.DoSave()
   THISFORM.DoRevert()
ENDIF
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform