This post is machine-translated. The original post in german language can be found here.

Create a picking list line for a production order

The following job creates a picking list line for a production order.

static void createProdJournalBOM(Args _args)
{
    AxProdJournalBOM axProdJournalBOM;
    InventDim inventDim;

    axProdJournalBOM = AxProdJournalBOM::construct();
    axProdJournalBOM.validateInput(true);
    axProdJournalBOM.continueOnError(true);

    axProdJournalBOM.parmProdId("P000194");
    axProdJournalBOM.parmJournalId("00950");
    axProdJournalBOM.parmItemId("M0014");
    axProdJournalBOM.parmBOMConsump(30);
    axProdJournalBOM.prodJournalBOM().initFromInventTable(InventTable::find(axProdJournalBOM.parmItemId()));

    // Lagerungsdimensionen (optional)
    inventDim = axProdJournalBOM.prodJournalBOM().inventDim();
    inventDim.InventSizeId = "1000";
    inventDim = InventDim::findOrCreate(inventDim);
    axProdJournalBOM.parmInventDimId(inventDim.InventDimId);

    axProdJournalBOM.save();
}
These post applies to following version:
Dynamics AX 2012

 
 

 

 
 
 
Posts of the actual month
November 2024
MoTuWeThFrSaSu
 123
45678910
11121314151617
18192021222324
252627282930 
 
© 2006-2024 Heinz Schweda | Imprint | Contact | German version | Mobile version
In order to provide you with better service, this site uses cookies. By continuing to browse the site, you are agreeing to our use of cookies.