Hi All,
I'm fairly new with NAV Coding. Can you please tell me what I'm doing wrong:
I want to calculate the SUM of quantities in "Item Ledger Entry" filtered by the Users "Shortcut Dimension 1 Code".
In the Item Table fields are:
- "Global Dimension 1 Filter"
FieldClass = FlowFilter
TableRelation = "Dimension Value".Code WHERE (Global Dimension No.=CONST(1))
- "InvQty" (for getting the sum of quantity)
FieldClass = FlowField
CalcFormula(Sum("Item Ledger Entry".Quantity WHERE (Item No.=FIELD(No.),Global Dimension 1 Code=FIELD(Global Dimension 1 Filter)))
In the List Page I did this
- OnOpenPage
IF UserSetup.GET(USERID) THEN
VALIDATE("Global Dimension 1 Filter",UserSetup."Shortcut Dimension 1 Code");
MESSAGE('%1',"Global Dimension 1 Filter"); -- Just for checking if getting the correct data
I'm getting the total of all quantity and not filtered by "Shortcut Dimension 1 Code".
Please help
Thanks.
*This post is locked for comments
I have the same question (0)