Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Unanswered

Capture SOP number after clicking Generate PO button on SOP Entry screen

(1) ShareShare
ReportReport
Posted on by 75,848 Moderator

I need to capture the SOP number off the POP Preview Screen when generating a PO off a sales order. I can see the SOP on the sales tab and I thought it would be contained in

SopPoPreviewWindow.SoLineDetail.SopNumber

I am using this event

SopPoPreviewForm.SopPoPreview.LocalGeneratePoPb.ClickAfterOriginal += new EventHandler(UpdatePOPCosts_Change);

When I use this the SopNumber is not assigned a value. Should I use a different event or a different value?

Categories:
  • Richard Wheeler Profile Picture
    75,848 Moderator on at
    RE: Capture SOP number after clicking Generate PO button on SOP Entry screen

    Thanks for this tip. I will give it a try.

  • Almas Mahfooz Profile Picture
    11,009 User Group Leader on at
    RE: Capture SOP number after clicking Generate PO button on SOP Entry screen

    I had similar requirement and I did it by registering InvokeAfterOriginal event on procedure PoGetAddNewSuitable.

    And got the required values from there.

  • Richard Wheeler Profile Picture
    75,848 Moderator on at
    RE: Capture SOP number after clicking Generate PO button on SOP Entry screen

    GPPT was helpful in solving this issue. I found it was easier to capture the click event of the Action button to get the SOPNUMBE and SOPTYPE as they are still present on the form. Then I capture the Generate click event to fire off a stored procedure that sets all PO costs to what was on the SOP lines.

  • David Musgrave MVP GPUG All Star Legend Moderator Profile Picture
    14,053 Most Valuable Professional on at
    RE: Capture SOP number after clicking Generate PO button on SOP Entry screen

    Hi Richard

    Did you log scripts to see what is running? You should be able to find a spot that will allow you to get to the data.

    You can use GPPT to do the logging with a single click for you.

    Regards

    David

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

Ramesh Kumar – Community Spotlight

We are honored to recognize Ramesh Kumar as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

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

#1
Abhilash Warrier Profile Picture

Abhilash Warrier 565

#2
Martin Dráb Profile Picture

Martin Dráb 536 Most Valuable Professional

#3
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 402 Super User 2025 Season 1

Product updates

Dynamics 365 release plans