Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Grid Question
Message
De
09/12/1997 11:24:56
Rebecca Stottlemire
Kansas State Department of Commerce
Topeka, Kansas, États-Unis
 
 
À
03/12/1997 16:47:19
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
Divers
Thread ID:
00063629
Message ID:
00064689
Vues:
49
>>I have a grid on a form which displays a set of records from a file (with a filter set).
>>There are 8 columns and variable rows, depending on the filter.
>>I have put text fields below the grid showing the totals of each column. I get these totals with SQL select and fill an array. The problem is that I can't refresh these totals using the SQL select into the array until after a TABLEUPDATE.
>>Is there an easier way to sum the values of the columns in the grid?
>
>You could use parameterized table-buffered view as Grid.Recordsource. Then you use CALCULATE SUM... from Grid.Column.Text.InteractiveChange event, assuming that you will restore record pointer.

Hi, thanks for the info. I tried this in the interactive change event (which fires for each number entered) for the column and for the lost focus for the column, it works, but the numbers I get aren't the correct totals for the columns--I don't know what they are! At first I thought perhaps it was ignoring the filter, but that's not the case.
I used CALCULATE SUM(thisform.grid1.column1.text1.value) to thisform.totals(1)
Any more ideas?
Thanks loads! Becky
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform