Skip to main content

Notifications

Small and medium business | Business Central, N...
Unanswered

Codeunit customization to Auto Post Non-Invt. Items for Dropshipment Sales Orders.

Posted on by
Hey Guys,
 
We are using Non-Invt Items with General Prod. Posting Group /FREIGHT/ add freight charges to the Sales and Purchase Orders, instead of Item Charges. 
 
For the Dropshipment orders, we had multiple scenarios where the freight line had to added to Sales Orders, but do not require it in a linked purchase order, as we have our own freighting companies to pick up P.Os from vendor, as forward freight. 
 
For these orders, we cannot automatically post freight lines in Sales Orders, as the freight line is not linked to P.O.
 
 
To address this issue, I am trying to develop a custom codeunit, and using Event handler, I am hoping to post the Sales Lines similar to the /Auto Post Non-Invt. via Whse. / function in BC, as below . 
 
 
I am struck at this stage, as I am struggling to figure out the exact trigger in codeunit: / Purch.-Post /. 
 
Can anyone suggest if I am on the right track, and which trigger I can use in this scenario.
 
Thanks in advance for any help
 
 
 
Categories:

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,240 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,149 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans