06-13-2011 11:16 AM
Hi All,
I want to make NETPR and KBETR fields display only on ME22N, I have used the BADI ME_ACTV_CANCEL_PO but there is no success. I cannot see the change on ME22N. Would somebody help me out with this. Here is my code
if sy-tcode = 'ME22N'.
assign ('(SAPLMEGUI)TC_1211-COLS') to <fs>.
if sy-subrc is initial.
loop at <fs> assigning <ls>.
assign component 'SCREEN' of structure <ls> to <lr_screen>.
if <lr_screen>-name = 'MEPO1211-NETPR'.
read table <lr> assigning <lr_screen> with table key name = 'MEPO1211-NETPR'.
if sy-subrc = 0.
loop at screen.
<lr_screen>-input = 0.
modify screen.
endloop.
endif.
endif.
endloop.
endif.
endif.
06-13-2011 11:23 AM
hi,,
Try with <lr_screen>-active = 0.
Also, have you debugged and checked if the code goes inside your if statement?
Is teh BADI triggered at the relevant place?
also,
<lr_screen>-input = 0.
modify screen.
you are changing value od <lr_screen> instead of screen.And tehn you use modify screen statement.
Edited by: sap_wiz on Jun 13, 2011 3:53 PM
06-13-2011 11:56 AM
Hi SAP_wiz,
Yes, I have debugged it and it is stopping at right event. I have tried <lr_screen>-active = 0 it is working but it is also taking away the value of the field, i.e. it is making the field initial and no value is displayed on the screen. My requirement is I want to make it display only with the value..
Thanks
Manasiii
10-22-2013 11:44 AM
Hi Manasii,
I am too facing the same issue while editing a standard table control in ME22N transaction. When I use active = 0; the field becomes initial and no value is displayed on the screen. Can you please share how you fixed this bug.?
Thanks in advance.
thanks,
Vivek