static void Job72(Args _args)
{
//1045_074
ProdTable prodTable;
ProdMultiStartUp prodMultiStartup;
ProdMultiStatusDecrease ProdMultiStatusDecrease;
ProdParmStatusDecrease ProdParmStatusDecrease;
;
// //find ProdTable, not nessary in your case
prodTable = ProdTable::find("1066_074");
prodTable.ProdStatus = prodStatus::StartedUp;
select * from prodTable where prodTable.ProdId == "1066_074";
ProdParmStatusDecrease.initFromProdTable(prodTable);
ProdParmStatusDecrease.initParmDefault();
ProdParmStatusDecrease.insert();
ttsbegin;
select forupdate * from ProdParmStatusDecrease where ProdParmStatusDecrease.ProdId == "1066_074";
if(ProdParmStatusDecrease)
{
ProdParmStatusDecrease.WantedStatus = ProdStatus::Released;
ProdParmStatusDecrease.doUpdate();
}
ttscommit;
// //init ProdStartup
ProdMultiStatusDecrease = ProdMultiStatusDecrease::construct(new args());
// //init default parameter
RunBaseMultiParm::initParm(ProdMultiStatusDecrease);
// //parm ProdTable, you can do this muliple times in case you want to update
//// more than one production at a time
ProdMultiStatusDecrease.insert(prodTable, ProdParmStatusDecrease);
// //Do update
ProdMultiStatusDecrease.run();
//ProdTable.status().runStartUp(prodParmStartUp);
//prodTable.autoUpdate(prodStatus::Released);
}
Subscribe to:
Post Comments (Atom)
How to identify the user that was used to change an object from AOT in AX2012
Get the object name for which we need to track these (user and date&time) information's. Login to SQL Server Management Studio an...
-
Combo boxes in Dialogs are added by adding a DialogField object with the type of an enum. The enum is then controlling what items you can pi...
-
This article explains: How to picking list through a job using X++ in Dynamics AX. Applied on: Dynamics AX 2009 SP1 Create a job a...
-
A while ago I had the need to translate labels, I was creating eMail bodys while using SysMailer and wanted to use different languages for d...
No comments:
Post a Comment