title: Out of range error by segmented entry
body: <p>I have new table. In which I created two new fields</p>
  
  <p>1) Name --> Dimension, EDT--> DimensionDynamicAccount</p>
  
  <p>2) Name --> AccountType, EDT--> LedgerJournalACType</p>
  
  <p>Now I want look up same as in "LedgerJournalTransDaily"  form. i.e When Accounttype == Ledger then Lookup from LedgerAccount
  When Accounttype == Customer then Lookup from CustTable.</p>
  
  <p>For This I have followed the step in Page 19 in white paper"Implementing_the_Account_and_Financial_Dimensions_Framework_AX2012" which you find here: <a href="http://download.microsoft.com/download/4/e/3/4e36b655-568e-4d4a-b161-152b28baaf30/implementing_the_account_and_financial_dimensions_framework_ax2012.pdf" rel="nofollow noreferrer">http://download.microsoft.com/download/4/e/3/4e36b655-568e-4d4a-b161-152b28baaf30/implementing_the_account_and_financial_dimensions_framework_ax2012.pdf</a></p>
  
  <p>Always when i go into my form, the error message "Argument to method getFieldValue out of range." is shown. </p>
  
  <p>So i set an debug point in "loadSegments" in the row "ledgerDimAccContr.parmControl(this);" 
  i run into this method and there is a line "if(this.isNonLedgerAccount())" and when i step into this method the call "DimensionHierarchyType  hierarchyType = this.getHierarchyType();" throws the error. </p>
  
  <p>Have anybody a idea how to solve this? </p>
  
  <p>You can find my Code here: <a href="https://community.dynamics.com/ax/f/33/t/231980" rel="nofollow noreferrer">https://community.dynamics.com/ax/f/33/t/231980</a> </p>
  
  <p>BG James</p>