I’m implementing validation in the MIRO transaction through BADI MRM_HEADER_CHECK. When I trigger an error indicating that the ‘reference’ field has been reused, it results in an error message of type E. This action locks all fields on the screen, preventing the user from correcting the input.
I intend to display this error type to restrict user input on all fields, except for two specific ones highlighted in red. Here’s what I’ve attempted so far:
- Using
MESSAGE <msg> TYPE 'S' DISPLAY LIKE 'E'
has not worked. - I’ve checked that the
SY-DINNR
variable equals 6000 at a breakpoint. - In my BADI code, the
LOOP AT SCREEN
does not show the fields I want to manipulate. - I cannot alter any code outside of my BADI, specifically within the PAI and PBO modules.
Here’s how my BADI is currently structured:
*Assigning the field values to process input.
ASSIGN ('(SAPLMR1M)RBKPV') TO <fs_rbkpv>.
IF <fs_rbkpv>-XBLNR = lwa_bkpf-xblnr.
MESSAGE lc_message TYPE 'E'.
ENDIF.
I’m looking for any advice on how to keep certain fields editable after displaying the error message while working within the limitations of BADI. Thank you for your help!