Dynamics AX provides a framework, which can be used to update production orders to a specific status. In the example, a production order is ended/finished.
If you want to update several production orders at the same time, you must invoke the ProdMultiHistoricalCost.insert() method per production order and pass the respective record of ProdTable.
Dynamics AX provides a framework, which can be used to update production orders to a specific status. In the example, a production order is ended/finished.
If you want to update several production orders at the same time, you must invoke the ProdMultiHistoricalCost.insert() method per production order and pass the respective record of ProdTable.
{
ProdTable prodTable;
ProdMultiHistoricalCost prodMultiHistoricalCost;
prodTable = ProdTable::find("P000195");
prodMultiHistoricalCost = ProdMultiHistoricalCost::construct(new Args());
RunBaseMultiParm::initParm(prodMultiHistoricalCost);
prodMultiHistoricalCost.insert(prodTable, prodMultiHistoricalCost.defaultParmBuffer());
prodMultiHistoricalCost.run();
}