Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Problems with TABLEUPDATE
Message
 
À
09/09/1998 17:08:57
Koos Veel
Gamma Research
Aruba
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00134814
Message ID:
00134840
Vues:
16
While newly added records are still in the buffer (that is, you've added them to a table with table buffering but haven't used TABLUPEDATE() yet) they have negative RECNOs. Try REPLACE ... FOR RECNO()<0.

>Hello,
>
>We are using Visual FoxPro 5.0 and have stumbled upon a bit of a problem.
>
>We try to create a form where we enter information about a new user for the security. After we have filled in the information we want we save the entered information. We use optimistic table buffering for all our tables used in this form.
>
>We want to add the new user (this works okay) to the Users table and then want to append to another table (UserAcc) some information we find in UserFunc. However when we execute the following routine which we have under the SAVE button:
>
>---
>TABLEUPDATE(.T.)
>*
>SELECT UserAcc
>SET FILTER TO
>SET ORDER TO
>GO BOTTOM
>mRecNo = RECNO()
>APPEND FROM UserFunc
>*
>REPLACE ALL UserName WITH THISFORM.Sec_Pgf1.Page1.txtLogin.VALUE FOR RECNO() > mRecNo
>*
>TABLEUPDATE(.T.)
>----
>
>This way the new user does get added to the physical users table. And also there is an append to the useracc table. But the replace command isn't executed. Nothing is replaced at all. I tried the same thing in the command window and it works.
>
>Is this because table buffering is used? How can we solve this?
>
>Thanks in advance for your time and answer!
>
>Greetings,
>Michiel Willems
>Using the account of Koos Veel
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform