AX Consulting

Just another site

Preform a PackingSlip Update through code


To continue on with post like the previous, below is code that will take a given salesid an perform a packslip update on it.
public packSlipUpSO(SalesId _salesid)
SalesFormLetter SalesFormLetter = SalesFormLetter::construct(DocumentStatus::PackingSlip,true);
SalesTable SalesTable = SalesTable::Find(_salesId);
SalesFormLetter.update(SalesTable,systemDateGet(), SalesUpdate::ALL, AccountOrder::None, false, false);
This is in short form, because that is what someone left comments about on the last post, so I thought I would put this in short form just for them! Anyway, if you notice the ‘SalesUpdate::ALL’. This enum tells the update posting that take the entire sales order and mark it has being packing slip updated. If you only wanted what was set as delivered now from within the sales line, then you could change this to the value: SalesUpdate::DeliverNow


Leave a Reply

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

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

Google+ photo

You are commenting using your Google+ 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 )


Connecting to %s

%d bloggers like this: