General information
Category:
Reports & Report designer
Thanks for all the help
I'll try the "long way" to see how it goes - BTW does anyone know if this is problem which has been fixed in the new version of VFP?
Wishfull thinking on my part no doubt!
Regards
Chris
>>Hi all
>>
>>I've noticed that when generating reports, VFP takes a blank field as a zero - which effects the average of the values at the end of a report I'm generating. Does anyone know a simple way to get around this - I've been exporting the tables to Excel, which simply ignores the blank fields (for the purposes of averaging)...but I'm quickly getting sick of doig it this way.
>>
>>Thanks in advance...
>>
>>
>>Chris Kable
>>FuelTrac
>
>Don't use Foxpro's native average calculation. Instead, use report variables to calculate your own average. Have one variable, nSum, that has an expression of IIF( <> 0, , 0) and has "SUM" marked as the calculation. Then create another variable, nCount, that has an expresion of IIF( <> 0, 1, 0) and mark "SUM" as the calculation. When you are ready to print the average, create an expression that is "nSum / nCount".
>
>It's more work on your part, but it will work.
>
>Cathy
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only