Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to add data to my Grid
Message
De
20/02/2003 19:04:25
 
 
À
20/02/2003 09:22:52
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00755482
Message ID:
00755870
Vues:
16
For the second part of your question, to ask and then save or abandon, use buffering:

In Load:
=CURSORSETPROP('Buffering', 5, 'MyDetailTable')

When saving:
IF MESSAGEBOX('Save this data?', 4, '')=6
=TABLEUPDATE(1, .T., 'MyDetailTable')
ELSE
=TABLEREVERT(.T., 'MyDetailTable')
ENDIF

If the data you are entering is to the detail table, set the grid RecordSource property to the alias of the detail table. Then when you want to add a record, INSERT INTO the detail table and refresh the grid to see the empty line. Cetin is right, it can be complex. If all your data can be input directly into the default textboxes in each column, you are probably okay having the user enter directly into the grid. If you want to validate any of the data against a lookup table, for example, then maybe a textbox is not the best control to have in the column, and the process is more advanced.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform