Active Ledger Dimension


Active Ledger Dimension 


You can use the following code sample to tet ledger dimension values for active account structure in AX 2012 & D365FO


  public static DimensionValue getdimensionValue(LedgerDimensionAccount _ledgerDimension, Name _dimensionName )
    {
        DimensionAttributeLevelValueAllView dimAttrView; //View that will display all values for ledger dimensionsDimensionAttribute dimAttr; //Main dimension attribute table

        select DisplayValue from dimAttrViewwhere dimAttrView.ValueCombinationRecId == _ledgerDimension //generalJournalAccountEntry.LedgerDimensionjoin BackingEntityType from dimAttrwhere dimAttr.RecId == dimAttrView.DimensionAttribute&& dimAttr.Name == _dimensionName; // Dimension field name
        return dimAttrView.DisplayValue;
    }

Support Faryal's Cusine


No comments:

Post a Comment

Virtual Fields Vs Computed Fields

  Virtual Field: A virtual field in D365FO is a field that doesn't have a direct representation in the database. It's a field that y...