≡ Menu




Financial dimension for work position Dynamics Ax 2012.

 

I used following code snippet to get financial dimension attached with hcmposition

 

static void GetFinancialDimensionValue1(Args _args)

{

HcmPosition  position;

HcmPositionDefaultDimension  positionDefaultDimention;

DimensionAttributeValueSetStorage dimStorage;

Counter i;

select * from position

join * from positionDefaultDimention

 

where position.PositionId=="000001"

&& position.RecId == positionDefaultDimention.Position;

 

 

 

dimStorage = DimensionAttributeValueSetStorage::find(positionDefaultDimention.DefaultDimension);

 

for (i=1 ; i<= dimStorage.elements() ; i++)

{

 

info(strFmt("%1 = %2", DimensionAttribute::find(dimStorage.getAttributeByIndex(i)).Name,

dimStorage.getDisplayValueByIndex(i)));

 

}

}

2016-08-15_23-14-22

 

Reference:  https://jkmsdax2012.wordpress.com/2015/11/16/how-to-get-financial-dimensions-for-a-particular-customer-using-x-code-in-ax-2012/

{ 0 comments… add one }

Leave a Comment