Update picking list for sales order Using X++ code Dynamics AX 2012 R2

We can generate the picking list for sales order with X++ Code.

Following X++ code example will help you to update picking list for specific Sales Order:

public static void UpdateSalesOrder_PickingList(Args _args)

{

SalesFormLetter_PickingList salesFormLetterPickingList;

SalesTable salesTable = salesTable::find(‘SAO-12345’);

salesFormLetterPickingList = SalesFormLetter_PickingList::newPickingList();

salesFormLetterPickingList.transDate(systemDateGet());

salesFormLetterPickingList.update(salesTable,

systemdateget(),

SalesUpdate::All,

AccountOrder::None,

NoYes::No,

NoYes::No);

}

Note: For more control over data to be posted, you should take a look at the parameters of salesFormLetterPickingList.update(), Specifically parameter SalesUpdate enum.
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s