RustySunset
Technical User
I am trying to create a report that has amounts in columns by month. I will have twelve columns of data (no running total or grand total column) and need to be able to have the user enter an ending date which would control the date range of data selected. If they entered 06/30/07 they would get data for Jul-06 through Jun-07.
The transaction data is stored by date and there is several years of data (as in the example above. I have created the twelve formula fields for the 12 columns and am using the following formula with VERY limited success. It doesn't work when the year changes...
NumberVar Age_m1 := Month(DateSerial (Year ({?Ending Date}), Month({?Ending Date}) , 1));
NumberVar Age_y1 := Year(DateSerial (Year ({?Ending Date}), Month({?Ending Date}) -1, 1));
If Year ({tapVoucher.TranDate}) = Age_y1 And (Month({tapVoucher.TranDate}) = Age_m1)
Then {tapVoucherDetl.ExtAmt}
Else 0.00
Any help is appreciated. I am open to changes etc.
The transaction data is stored by date and there is several years of data (as in the example above. I have created the twelve formula fields for the 12 columns and am using the following formula with VERY limited success. It doesn't work when the year changes...
NumberVar Age_m1 := Month(DateSerial (Year ({?Ending Date}), Month({?Ending Date}) , 1));
NumberVar Age_y1 := Year(DateSerial (Year ({?Ending Date}), Month({?Ending Date}) -1, 1));
If Year ({tapVoucher.TranDate}) = Age_y1 And (Month({tapVoucher.TranDate}) = Age_m1)
Then {tapVoucherDetl.ExtAmt}
Else 0.00
Any help is appreciated. I am open to changes etc.