Sunday, May 21, 2017

How NAV Calculate Unit cost of items in NAV?

How to Calculate Unit cost in Reports of NAV?


Using the below code MS Dynamics NAV Calculates Unit Cost in Report of 746.

ItemRec.RESET;

ItemRec.SETRANGE(ItemRec."No.","No.");

ItemRec.SETFILTER(ItemRec."Date Filter",'%1..%2',0D,CALCDATE('-1D',SDate));

IF ItemRec.FINDFIRST THEN;

ItemCostMgt.CalculateAverageCost(ItemRec,AverageCost,AverageCostACY);

AverageCost := ROUND(AverageCost,GLSetup."Unit-Amount Rounding Precision");

No comments:

Post a Comment