Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Setting record source in grid
Message
De
17/02/2006 18:34:51
 
 
À
17/02/2006 17:59:53
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
01097227
Message ID:
01097237
Vues:
16
This message has been marked as the solution to the initial question of the thread.
>Suppose there is a form with a grid and a combobox that opens with no tables open. The user types the name of a file into a textbox and clicks a button to open the file. As in
>
>lcFileToOpen = txtbox.value
>use (lcFileToOpen) in 0 alias currenttable
>
>Then we issue:
>
>thisform.grid1.recordsource = currenttable
>thisform.grid1.init
>thisform.grid1.refresh
>
>but nothing happens.
>
>So my question is: How do you dynamically set a source table for a grid?
>
>As always, Thanks for any help on this one.
thisform.grid1.recordsource = "currenttable"
Or if you have it in a variable (cAlias = ALIAS("currenttable"), then you would use your syntax.

You need quotation marks to do it in code.
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform