Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Can I subgroup a summary?
Message
De
10/09/2002 11:56:46
 
 
À
10/09/2002 11:09:24
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire de rapports & Rapports
Divers
Thread ID:
00698436
Message ID:
00698839
Vues:
17
The details will be of one data group (say a date); but the date range is variable. Meaning, it can be two days or five days. Therefore, I have to have a way to be able to dynamically define variables and lay them out in the summary band.

>I'm at a loss then on how to accomplish this. What type of information is stored in the detail record that you need the subtotals for? I know I can do this with dates (in the example) because if my detail is a date field and an amount field (for instance), I can sum the date field by day(date) for example and then print the totals of the amount field in the summary band, but if you have different types of detail, that would not necessarily work.
>
>>The example you sent certainly meets my requirements except for the part where the number of unique details (or variables) are not known.
>>
>>>I sent you an example by email. It is quick and not very pretty, but if I understood you correctly, it should work. Basically, you would have to create a report variable for each detail type to total the amounts for each possible detail. Then display those totals (variables) in the summary band. The grand total is the easiest of course, so I did not include that in the report. You could use a print when statement in the properties and only print if the value is greater than zero. If you have a huge number of possibilities for detail items, then this would not work well. You may want to create the variables before you run the report then instead of using report variables only. I tend to use report variables whenever possible though to enable easily releasing them at the end of the report. I'm not sure what type of information your detail records are or I could try to come up with another solution. Maybe someone else will have a better idea!
>>>
>>>I'm thinking there's gotta be a better way...
>>>
>>>Tracy
>>>
>>>>Yes, it could. But how do I display the information in the summary?
>>>>
>>>>>Wouldn't setting up report variables for each of the details do this for you?
>>>>>>Hi all,
>>>>>>
>>>>>>Can I do this in VFP reports?
>>>>>>
>>>>>>
>>>>>>Group1
>>>>>>  1st Day
>>>>>>    Detail A   10
>>>>>>    Detail B   20
>>>>>>Group1
>>>>>>  2nd Day
>>>>>>    Detail A   20
>>>>>>    Detail C   10
>>>>>>Summary (All days)
>>>>>>    Detail A   30
>>>>>>    Detail B   20
>>>>>>    Detail C   10
>>>>>>Grand Total   60
>>>>>>
ramil
~~ learning to stand still
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform