Click to See Complete Forum and Search --> : 2 find total of each page individually
sirajcuet
May 26th, 2005, 05:19 AM
i m doing dis by running total
bt d problem s dat i need each page total individully,
how cn i do it.
for example
page-1
------------------
Amount
10
5
3
-------
total: 18
page 2
---------------
Amount
2
2
6
--------
total: 28
but i need the result as follows
page-1
------------------
Amount
10
5
3
-------
total: 18
page 2
---------------
Amount
2
2
6
--------
total: 10
wht can i do
Madhi
May 27th, 2005, 01:04 AM
You need to use three formulae for this
formula1 @Reset
numbervar n;
whileprintingrecords;
n:=0
formula2 @Sum
numbervar n;
whileprintingrecords;
n:=n+{Amount};
formula3 @Display
numbervar n;
whileprintingrecords;
n;
Place Formula1 at Report Header and suppress
Place Formula2 at Details Section and suppress
Place Formula3 at Report Footer and dont suppress
sirajcuet
May 28th, 2005, 12:12 AM
tnx madi
i m doing ur code
but i m in another problem
when i m writing
n:=n+{amount};
a problem is arising
a number is required [error location on after equal sign & before n]
but if i remove : there is no error;but the sum is not being created.
wht shoul i do?
i m using crystal syntax
ooh
my in my project {amount} is also another formula
so i m using{@amount}
plz help me.
Madhi
May 30th, 2005, 12:41 AM
Try to use second formula as
numbervar n;
whileprintingrecords;
n:=n+ToNumber({@Amount});
sirajcuet
May 31st, 2005, 01:35 AM
thank you for reply
it is working as my expectation
i think u will help me in this way
again tnx
siraj
codeguru.com
Copyright WebMediaBrands Inc., All Rights Reserved.