Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Referencing a field with an unknown name
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00086557
Message ID:
00086626
Vues:
25
>fld = "cpp."+alltrim(trips.dwn_region)
>trips.copay = fld

Suggestions:
- say: Replace Trips.Copay with Eval(fld)
- You can do some helpful things with SQL statements. For example, you can build your entire UI off of a table with known (or systematically generated) field names. You would populate this table (or cursor) with a dynamically generated SQL statement that essentially remaps "unknown" fields (or generates entire new fields from combinations of "unknown" fields) from your universe of all field names.
- You can dynamically set the controlsource for each column in a gird, so that the grid maps onto your fields of interest. You can also dynamically set the # of columns in a grid.
- VFP's GenXTab utilitity might be helpful along the way.
- If the need arises, you can use name substitution as follows:
--For memory variables: Store Some_Expression to (cMvName)
--For fields: Replace (cFieldName) with Some_Expression
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform