Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
Showing results for 
Search instead for 
Did you mean: 

ME22N : Some Item fields should be locked for editing

Active Participant
0 Kudos

Dear all,

First of all, I would like to apologise if the solution is already somewhere on this forum ... I have been searching and reading since this morning, but I didn't find anything that could help me to solve my problem ...

My problem is the following: when we open a purchase order via ME22N, we check if there is already a related production order ... If so, some fields on item-level (material, quantity, date, ...) should be locked for editing ...

I tried a lot of user-exits but no one did what I want to do ... There are also a lot of treads about using BADI's, but I am not able to make this work this way ... I probably do something wrong, but I don't know what ...

Can anyone assist me in changing the properties of some fields ?




0 Kudos

Dear Kurt,

       If suppose , for that PO MIGO has been completed then we can't edit that line item.

Can you elaborate the same.



0 Kudos

Dear Krishna,

The problem is that the line items can be edited, even is there is a related purchase order ... We want to change that ... If there is a related po, we want to disable some fields (display only) ...



0 Kudos

Dear kurt,

         you want to keep some fields to be hidable then try SHD0 transaction variant.

then we can edit those fields.

Thanks & Regards,


0 Kudos

Hello Kurt,

As per my knowledge, there is no standard enhancement available for such requirement.

There is a BADI MEGUI_LAYOUT is available but it is a Internal SAP use only.

Hence it is not possible to create implementation of the same.

You can design requirement by implementing implicit enhancement of function module MEPOBADI_LAYOUT.


You can find all the fields with DISPLAY_ONLY flag. After setting 'X' to this flag DISPLAY_ONLY, it will display as read only.

Kindly check and let me know if this helps.


Vishal Solanki

Former Member
0 Kudos

Hi try to create a screen layout for PO.

IMG--> Materials Managment --> Purchasing --> Purchase Order --> Define Sceen Layout at Document Level