Need Help using FlowField

Iqbal_FebrianoIqbal_Febriano Member Posts: 66
My client needs to see their item sales and purchases according to specific salesperson and principal. So we made Global Dimension 1 Code as Principal Code and Global Dimension 2 Code as Salesperson Code.
Then, I made a form with Table 27 (Item) as Source Table and put Global Dimension 1 Filter, Global Dimension 2 Filter, and Date Filter controls. I hoped when I change the value in those controls, the Purchase (Qty.) and other fields that alike will also change accordingly.
It works fine when I typed in Date Filter control :lol:, but when I put a value in Global Dimension 1 Filter or Global Dimension 2 Filter control, this error message showed up
[color=blue]The FlowField value cannot be calculated

    You must define and activate a key that contains the key fields that  appear below and then associate the specified SumIndexFiled with it

   Key Fields : Global Dimension 1 Code, Item No., Entry Type
   SumIndexField : Invoiced Quantity
   Table : Item Ledger Entry[/color]
:(
I know that Item Ledger Entry table has Keys containing Global Dimension 1 Code, Item No., and Entry Type. I just couldn't find out where should I put a code to activate the key. I tried to put
ItemLedgEntry.SETCURRENTKEY("Global Dimension 1 Code",...)

in OpenForm, OnGetCurrRecord, OnAfterGetCurrRecord triggers, also in Control -Validate and AfterValidate, but it didn't work

Help me please :cry:
Be fast, be straight, be quiet

Comments

  • pdjpdj Member Posts: 643
    Navision automatically selects which key to use when calculating flowfields, so you can't solve it by adding code.
    The problem must be in the key you have created.
    When the error msg say you should "activate it", it simply means it should be enabled by having a checkmark in the keys window.
    I have always been able to use this error msg very detailed. So if you have created the key as specified and remembered to set Invoiced Quantity as SumIndexField I can only find two issue left. Is MaintainSIFTIndex and MaintainSQLIndex set to yes? Is SIFTLevelsToMaintain set to maintain all levels?

    Otherwise I'm blank :(
    Regards
    Peter
  • Iqbal_FebrianoIqbal_Febriano Member Posts: 66
    Thanx Peter, you're right. Apparently I have enabled a wrong key :)
    Be fast, be straight, be quiet
Sign In or Register to comment.