I've a variable Total on a detail band (price X qty = total) that is working fine. However I want to to SUM total on the group footer. I just can't figure how to approach this. Any advice?
Your code appears correct. Check the ResetType property and be sure the value is not being reset at the incorrect time.
If you are still having issues, you can send a simple example demonstrating this problem using only Delphi and RB components in .zip format to support@digital-metaphors.com and I'll take a look at it for you. Please include your current RB serial number as well.
Comments
Which version of ReportBuilder and Delphi are you using?
One option is to simply place a TppVariable inside the group footer
band, then update its in the OnCalc of the variable in the detail.
Value := Price * Quantity;
TotalVar.Value := TotalVar.Value + Value;
--
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
I currently using RB 18.0 Ent and Berlin Professional.
I try your advice, but it only shows the value from the last detail line.
Here's the code I'm using:
procedure varTotalCategoriaOnCalc(var Value: Variant);
begin
Value := invExistencia['costo_unitario'] * invExistencia['existencia'];
varTotalCategoria.Value := varTotalCategoria.Value + Value;
end;
Is this what you meant?
Regards,
Mario
Your code appears correct. Check the ResetType property and be sure the
value is not being reset at the incorrect time.
If you are still having issues, you can send a simple example
demonstrating this problem using only Delphi and RB components in .zip
format to support@digital-metaphors.com and I'll take a look at it for
you. Please include your current RB serial number as well.
--
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Thank you Nico, I just sent you the sample project.
Thank you for your support.
Regards,
Mario