This article will explained how to implement enhancement to create custom fields in Purchase Orders ( PO ) and RFQ ( ME41 ). this enhancement use MM06E005.

This is an Enhancement package which has options to enhance functions and screens of some bussiness transaction which you can check from transaction SMOD.

This Enhancement MM06E005 Contains Some FM exits and Screen Exits to Enhance the Purchasing Transactions ME21(P.O), ME31 (Contracts) ME41( RFQ).

We can use this enhancement to Integrate Customer subscreens using the Screen Exits and Process the Logic using FM Exits.

The Functional Exit MM06E005 is the Enhancement for Customer fields in Purchasing document.

With this Enhancement ,

You can,

– Maintain/Supply your own Customer Fields in the Headers & Items of all Purchasing documents except Purchase Requisitions
– Update your own Customer-Specific Tables

You cannot,

– Change Standard Fields
– Change Data that depends on the Document Header in the Items
– Change Data that depends on an Item in the Document Header

INCLUDES

You incorporate your customer fields for the Document Header in the INCLUDE CI_EKKODB (in table EKKO).

You incorporate your customer fields for the Document Item in the INCLUDE CI_EKPODB (in table EKPO).

Dynpro Areas
If you use the Enhancement,U must create & generate the following dynpros (even if the dynpros are not going to be used):

– SAPLXM06 0101 Subscreen Header Purchase Order
– SAPLXM06 0201 Subscreen Header Outline Agreement
– SAPLXM06 0301 Subscreen Header RFQ
– SAPLXM06 0111 Subscreen Item Purchase Order
– SAPLXM06 0211 Subscreen Item Outline Agreement
– SAPLXM06 0311 Subscreen Item RFQ

You must identify all dynpros as subscreens. It is not necessary that they contain fields, but it is essential that they exist in order that no program abend occurs.

Functional Exits
The Dynpros are linked to the Standard Program via Function Modules.There are Function Modules that provide your subscreen with data (Export) and Function Modules that fetch data from your subscreens (Import).

-> Header Screens :

– EXIT_SAPMM06E_006 – Export Data to Customer Subscreen for Purchasing Document Header (PBO)

– EXIT_SAPMM06E_007 – Export Data to Customer Subscreen for Purchasing Document Header (PAI)

– EXIT_SAPMM06E_008 – Import Data from Customer Subscreen for Header

-> Item Screens :

– EXIT_SAPMM06E_016 – Export Data to Customer Subscreen for Item (PBO)

– EXIT_SAPMM06E_017 – Export Data to Customer Subscreen for Item (PAI)

– EXIT_SAPMM06E_018 – Import Data from Customer Subscreen for Item

Step by Step

1. Create Project Enhancement use tcode CMOD.

cmod1-300x246

Type Project name and klik Create, on next screen type your description, then klik Enhancement Assigment.

2. Type MM06E005 on Enhancement Assignments, klik Components.

We must add custom field in Include Table :
  • CI_EKKODB :  Header Data
  • CI_EKPODB  :  Item Data

to create screen for PO Header, double klik on Screen Exit 0101, You must choose Subscreen Screen Type 

Then create layout screen like this or according to your requirement

we can put logic for screen modified in PBO, we can disable input or enable input to your custom field, if ME23N your custom field only display but when user run change PO ( ME22N) your custom field will enabled.

Note : GV_TRTYP is value from function exit , TRTYP = V is change or new PO, and VRTYP = A is display, see below
 
Now we continue to put logic in 2 function exit :
  • – EXIT_SAPMM06E_006 – Export Data to Customer Subscreen for Purchasing Document Header (PBO)
  • – EXIT_SAPMM06E_008 – Import Data from Customer Subscreen for Header

EXIT_SAPMM06E_008 is exit to import data from your customer subscreen to header data ( EKKO ). so your custom data can save into EKKO table

EXIT_SAPMM06E_006 is exit to put your custom data into custom screen.

ZXM06TOP  

Result:

So if you want to more understand about SAP ABAP Enhancement, I Highly recomended that you check out this good book.

Incoming search terms:

Leave a Reply

Your email address will not be published. Required fields are marked *