Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Calculated fields in a grid
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Problèmes
Divers
Thread ID:
00084340
Message ID:
00084410
Vues:
34
>>In FPW/FPD, I could create calculated fields in a BROWSE by doing;
>>maddress = address1+city+st :H = "Address"
>>
>>In the VFP 5 sample solutions app there is a grid with a calculated field, but the data is bound to the grid in the form (see vfp\samples\solution\controls\grid\calc.scx)
>>
>>I want to do something similar, such as turn a character field from values of "1","2" to "J","S" at runtime, not binding the recordsource before runtime.
>>
>>It doesn't seem to work as you would expect.
>>
>>Any help would be greatly appreciated.
>
>Michael, you can set column.ControlSource to (None) at design time,
>and at the runtime reset it for example to column.ControlSource = IIF(myfield = "1","J","S") if it is what you mean.
>
>HTH, Nick

Michael, you can even use Column.ControlSource="thisform.setcolumn()", where Setcolumn is form's custom method (like UDF).
Edward Pikman
Independent Consultant
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform