Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Suggested answer

post invoice for purchase order with charges x++

(0) ShareShare
ReportReport
Posted on by 405

Hi,

I am trying to post invoice for purchase order using x++ code.

using VendInvoiceInfoTable and VendInvoiceInfoLine table to pass value in class PurchFormLetter I am able to post PO with related all information .

once coming with charges not able to find any place where i can write markup code with amount to post with PO.

let me know if any one  aware  where i can write code?

Thank You.

  • shubhi gupta Profile Picture
    405 on at
    RE: post invoice for purchase order with charges x++

    Hi Sukrut,

    I am adding charges in header level. PO created manually and once we are doing invoicing via x++ that time i need to pass markup code and amount.

    I already debug the code but did not found.

  • Rahul Singh Rathod Profile Picture
    62 on at
    RE: post invoice for purchase order with charges x++

    In this scenario, you need to understand the invoice flow manually via debugging for charges related. Then you have to apply the same process in your custom logic.

  • Suggested answer
    Sukrut Parab Profile Picture
    71,637 Moderator on at
    RE: post invoice for purchase order with charges x++

    The charges  can be at PO header lever or PO line level . If you are putting the charges at header level , you have to allocate those charges to line and that is also depends on how you set up your charges code. As long as you have charges on PO header or line , those charges should be coming on your invoice from the PO.

    You have not provided enough details about your scenario but based on what you are saying , looks like you are creating invoice through x++ as well, if that is the case , take a look at details how charges are copied over to invoice when you generate invoice manually and you have to implement similar logic to copy over those charges.

    If you are just posting invoice through code which is created by someone as pending vendor invoice , charges should already be there copied from PO.

  • shubhi gupta Profile Picture
    405 on at
    RE: post invoice for purchase order with charges x++

    Hi Judy,

    no, its not sending charges information.

  • huijij Profile Picture
    19,801 on at
    RE: post invoice for purchase order with charges x++

    Hi Sir,

    When you call the update() method on the PurchFormLetter,Did it not send charges as well?

    regards

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

Dynamics 365 Community Update – Sep 16th

Welcome to the next edition of the Community Platform Update. This is a weekly…

Announcing Our 2024 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Dynamics 365 Community Newsletter - September 2024

Check out the latest community news

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

Overall leaderboard

Product updates

Dynamics 365 release plans