How to get inventory on-hand in Dynamics AX 2012 Through X++


How to get inventory on-hand in Dynamics AX 2012 Through X++


    InventDim           inventDim;
    InventDimParm   inventDimParm;
    InventOnHand     inventOnHand;

    inventDim.InventLocationId = "01";
    inventDim.modifiedField(fieldNum(inventDim,InventLocationId));


    inventDimParm.initFromInventDim(inventDim);

    inventOnHand = InventOnHand::newItemDim("111001", inventDim, inventDimParm);


 inventOnhand.availPhysical();

Comments

Popular posts from this blog

How to loop through enum in dynamics ax 2012 using x++

How to read from csv file in Dynamics AX 2012 Through X++

How to Create Transfer Journal in Dynamics AX 2012 Through X++