Hi Reader's,
lets learn small tip to show up display value based on default dimension with respective Dimension attribute in ax 2012
Note:
1)Here DimensionDefault is financial dimension combination( i.e recid),
2)Name is Like Dimension attribute name(ex Department).
public static
DimensionValue getDimensionValue(DimensionDefault _dimensionDefault, Name
_dimensionAttributeName)
{
DimensionAttribute attribute;
DimensionAttributeValueSetItemView
valueSetItemView;
attribute
= DimensionAttribute::findByName(_dimensionAttributeName);
select
DisplayValue from valueSetItemView
where
valueSetItemView.DimensionAttributeValueSet == _dimensionDefault
&&
valueSetItemView.DimensionAttribute == attribute.RecId;
return
valueSetItemView.DisplayValue;
}
Keep Daxing !!!
No comments:
Post a Comment