CodeCharge Studio
search Register Login  

Web Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> PHP

 [solved] - report issue - questions

Print topic Send  topic

Author Message
kirchaj

Posts: 215
Posted: 09/28/2009, 11:49 AM

I have a fairly simple report that lists scores and then gives an average for each group and an average for all of the groups. I have added an image label with custom code in the before show event to display one image if the group average is above 2.5 and a different one if below 2.5. This works great for body of the report. When I use similar code to display the image in the footer area, the code does not display the correct images.

I have doubled and triple checked the code and I believe it is OK. When I tried echoing the total average, it did not display correctly. So I think I am not retrieving the total average in the correct way. Can anyone shed any light on the way to get the total average (value from that label) which is located in the footer area?

Thanks for any ideas.

TK
View profile  Send private message
kirchaj

Posts: 215
Posted: 09/30/2009, 1:17 PM

Ok, here is what I found. By default, all averages in a report are set to integer. At least averages of integer fields are set this way. When you do a GetValue on the average, PHP or CCS rounds the number. When I set the average labels to float, the GetValue produced the correct answer.

Can't tell you why averages are being set to integers, but it was easy to fix.

TK
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Web Database

Join thousands of Web developers who build Web applications with minimal coding.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.