>>>I have a report with data grouping.
>>>How can I count the number of the groups?
>>>Thank you.
>>
>>add a variable to the report, set to count, reset at desired group.
>
>This doesn't count the groups. Report variables are calculated in the detail level.
>
>Vlad
Joco, You can do it with 2 variables. One tracks the value of the group and one tracks the total count of groups.
For example, if your group breaks on a field 'MyData.TYPE' Make 2 variables. The first is cType, Value to Store: MyData.TYPE, Initial Value: '' (Use the correct type here, '0' for numeric, etc.)
The second is GroupTot,
Value to Store: grouptot + iif(ctype = MyData.TYPE, 0, 1), Intial Value: 0.
Put them BOTH in the group footer. If you don't want to see the cType variable, simply set the Print When to .F..
HTH
Barbara