Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Display sum of two fields on grid
Message
 
 
À
03/12/2000 23:05:06
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00448679
Message ID:
00448680
Vues:
12
>Hello all,
> I have a grid show a list of record each with two numeric fields, I want to use an additional column to show the sum of that two fields on the fly. how can I do this?
>
>Because I don't want to define that 'sum' field on tabel structure, I have following problems:
>-I have try use local view, but local view have no index, so I can't use it to link to parent record.
>-I have try the assign method of that tow field to update the sum column display, but it is unreliable that all row's 'sum' column display the current record's 'sum'
>-I have try to create a temp table which have that 'sum' field and link to my table. And set the controlsource of column 'sum' to that temp table, but it also doesn't work.
>
>Could you help me?
>-Jasper

Jasper,
Try creating the view again but this time, open it with NODATA. Create the necessary index. Because there are no records, the index creation will be very fast *g*. Then requery the view. This should populate your summary field as well as provide a means of linking it to the parent table.

HTH.
Larry Miller
MCSD
LWMiller3@verizon.net

Accumulate learning by study, understand what you learn by questioning. -- Mingjiao
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform