Hi All Crystal Experts,
In my report, data is grouped by months and I have monthly view of data. I have three prompts- Year, Startdate and Enddate. If I give 2013 as year, 1/1/2013 as start date and 05/01/2013 as end date then report shows monthly view of data for Jan-13, feb-13, Mar13, Apr-13 and May-13. Now in report, for each month, I want three additional columns, I want to show last 12month, 6 month and 3 months view. Like for Jan-13 month, in column 6 months, I want to show data for last 5 months including current month i.e. Jan-13+Dec-12+Nov-12+Oct-12+Sep-12+Aug-12 and in Column 12months view, I want to show accumulated data of last 11 months(+ current month) and in 3 months view, data for last 2 months(+ current month).
I had tried creating Sub report for 12 months view and created Running total formula but it is not showing any value in report. It is blank. I have created running total like this way:
(1) "Running total formula" (which I am using and placing on group footer):
(I) Field to summarize- @Cash_total
(ii) Evaluate (use a formula):
WhilePrintingRecords;
NumberVar Cash_total_12 months;
If Month ({@Month_PostDate}) In [(Month {?StartPostDate} - 11) to Month
{?StartPostDate}] Then
Cash_total_12 months := Cash_total_12 months + {@Cash_Total};
(iii) Reset (use a formula):
WhilePrintingRecords;
NumberVar Cash_total_12 months=0;
When I placed this formula in group footer, it is showing nothing.
Please suggest me formula. Quick help would be much appreciated.
Thanks,