Populating UD Field on PO Entry Header with Data from Vendor Table UD Field

I have searched all throughout this forum but could not find something similar to what I am trying to accomplish. We have a UD field on our Supplier’s Maintenance screen entitled “Class”.

When a new PO is created, we would simply like for that Supplier’s UD “Class” field’s information to show on the PO Header in the allocated space (also a UD field in the POHeader).

What is the best approach to accomplish this? A Method Directive? A C# Customization using the POHeader_AfterFieldChange event handler on the “VendorVendorID” field?

Totally a beginner with these sort of customizations, but this one seems simple enough. So hoping it is not too difficult or involving to achieve. :slight_smile:

I’d go with a Method Directive BPM. Enable tracing, then enter a vendorID in the form to see which BO method is called when the vendor info is fetched. The BPM would need to set the ttPOHeader.Class_c field.

Since this is new. Do the BPM a little at a time. First just show a message to ensure you’re in the right BOM. Next display the Class field from the Vendor table. Then try setting ttPOHeader table.

I’d also add a data directive with a condition on a new POHeader record. PO’s get created from MRP or from PO Suggestions, the method directive would only catch PO’s created through PO Entry.

One could make a point that you only need the method directive, but it might be possible that a user creates a NEW PO with a vendor which would kick in the data directive, but then if they change the vendor ID AFTER the PO was created, you’d want the method directive to catch those situations.

One final note: I’ve had issues in pretty old versions of Epicor (I think going back to Vantage 8) where a data directive caused some performance issues with MRP, so you may want to do some testing. I’ve not seen that issue for years, but you can’t overtest.

1 Like

Many thanks to both Calvin and Kevin for your input. It helped tremendously!
Most appreciated gentleman!