How do I calculate sub total in MS Dynamics NAV?


I have to calculate total os the follwing calculated field.

=Fields!TempAppliedCustLedgEntry__Amount_to_Apply_.Value * DateDiff(“d”, Fields!TempAppliedCustLedgEntry__Posting_Date_.Value, Fields!Cust__Ledger_Entry__Posting_Date_.Value)

Thank you


This is not Navision code! Where are you creating this code?

This looks like sql reporting services. You need to add a group footer/header and add the field as text.

Thank you Rashed Amini. I modify my reports using Visual Web Developer.