Skip to main content

Notifications

Announcements

No record found.

Finance | Project Operations, Human Resources, ...
Unanswered

Before Purchase order - Product receipt posting, which method get called from which class ?

Posted on by 5,901

Hi,

Can you please let me know  Before Purchase order - Product receipt posting, which method get called from which class ?

Please give me more shed on this. 

Thanks!

  • André Arnaud de Calavon Profile Picture
    André Arnaud de Cal... 291,269 Super User 2024 Season 2 on at
    RE: Before Purchase order - Product receipt posting, which method get called from which class ?

    Hi @rp@n,

    I think we are now back at the start of your question. What is "before OK clicked"? On dialog open? After update of a certain control? Or automatically when the user did not do anything in 20 seconds?

  • @rp@n Profile Picture
    @rp@n 5,901 on at
    RE: Before Purchase order - Product receipt posting, which method get called from which class ?

    Hi Andre,

    8662.S1.jpg

    is this PurchFormLetter_PackingSlip is right class to do ? 

    Please give me more shed on this.

    thanks!

  • @rp@n Profile Picture
    @rp@n 5,901 on at
    RE: Before Purchase order - Product receipt posting, which method get called from which class ?

    Hi Andre,

    Please reply on this.

  • @rp@n Profile Picture
    @rp@n 5,901 on at
    RE: Before Purchase order - Product receipt posting, which method get called from which class ?

    Hi Andte,

    As you mentioned,  if posting field is enabled then only actual posting will start after clicked ok on posting dialog.

    As per my business requirement ,

    I have to perform before Product Recepit posting.

    That means , my code should get execute before ok clicked in posting dialog .

    Is it correct?

    Kindly let me know,  which class I needs to do the code?

    Please help me on this.

  • @rp@n Profile Picture
    @rp@n 5,901 on at
    RE: Before Purchase order - Product receipt posting, which method get called from which class ?

    Thanks Andre and Martin

    Kindly let me know in which class I need to do the code?

    Pls help me on this.

    Thanks!

  • André Arnaud de Calavon Profile Picture
    André Arnaud de Cal... 291,269 Super User 2024 Season 2 on at
    RE: Before Purchase order - Product receipt posting, which method get called from which class ?

    Hi @rp@n,

    The product receipt number is mandatory. Before just filling this field and click on OK, you might review other settings on this form first. If the 'Posting' field is unchecked, it will only generate a pro-forma for printing purposes, but will not do the actual posting. If this field is enabled then, indeed, the posting will start.

  • @rp@n Profile Picture
    @rp@n 5,901 on at
    RE: Before Purchase order - Product receipt posting, which method get called from which class ?

    Thanks Martin,

    Specifically,  if i am talking about PO - product receipt

    1,2 - In posting dialog, we have to mentioned Product receipt number then we clicked on ok. Then actually posting will start.

    Am I correct ?

  • Martin Dráb Profile Picture
    Martin Dráb 230,198 Most Valuable Professional on at
    RE: Before Purchase order - Product receipt posting, which method get called from which class ?

    I'll answer your questions, although they seem to be missing the point.

    1. Yes, but don't forget that posting can run even without any dialog.

    2. No. The posting hasn't even started when you close the dialog. It's the same as with any other RunBase/SysOperation process with a dialog. You first collect inputs in a dialog, save data to variables (a contract in case of SysOperation) and only then you start the actual process.

  • @rp@n Profile Picture
    @rp@n 5,901 on at
    RE: Before Purchase order - Product receipt posting, which method get called from which class ?

    Thanks Martin,

    Don't worry on the Updating LedgerDimension ( main account ). They already have setup  etc...

    They only asked me to find the correct place to write code.

    please confirm the below things...

    1. before opening the posting dialog - If i wrote something , is considered as before posting.

    2. After closing the posting dialog - If I wrote something , is considered as after posting

    Is it correct?

  • Martin Dráb Profile Picture
    Martin Dráb 230,198 Most Valuable Professional on at
    RE: Before Purchase order - Product receipt posting, which method get called from which class ?

    Hmm, it sounds to me like that you don't need to do anything before posting. You seem to want to change the way how ledger posting works. For some reason, you don't want to use the account configured for this type of posting and you want to take the value from somewhere else. Can you explain why, please?

    Also, your code suggests that you want to control the logic based on a field on PurchTable. This may be a problem if you're doing a summary posting of orders that have different setup, i.e. they should be posted to different accounts. Think about it.

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!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans