12-18-2013 3:23 AM
Hello Experts,
Urgent help required
I have stuck in one problem .
I have used the badi process_item .
I had created a enhancement in me21n to make tax code as mandatory field.
Enhancement is working fine E04 system but when it is moved to T04 systems it is not working correctly
i.e, After passing the tax code value the status bar showing message as "No message issued during check " But message bar is showing the message please enter tax code
So help me in solving this issue.
* Fehlermeldung wenn Steuerkennzeichen nicht gepflegt ist bei EKORG 0001
IF ( sy-tcode = 'ME21N' OR sy-tcode = 'ME22N' ) and re_hdrdata-ekorg = '0001' AND re_data-pstyp NE '7' and re_data-mwskz IS INITIAL and re_data-LOEKZ eq ''.
* IF sy-tcode = 'ME21N' OR sy-tcode = 'ME22N'.
* IF re_hdrdata-ekorg = '0001' AND re_hdrdata-bsart NE 'UB'. " U02848 3.10.2013 15:12 CET
* IF re_data-mwskz IS INITIAL.
* message id 'ZMSG' type 'E' number '008'.
************************************************************************** Commenting and Adding code by Madhu 17.12.2013
* IF sy-langu EQ 'E'.
* MESSAGE 'Please enter the Tax code' TYPE 'E'.
* EXIT.
* ELSE.
* MESSAGE 'Bitte Steuerkennzeichen pflegen' TYPE 'E'.
* EXIT.
* ENDIF.
mmpur_metafield mmmfd_tax_code.
mmpur_message_forced 'E' 'ME' '563' '' '' '' ''.
* invalidate the object
CALL METHOD im_item->invalidate( ).
*************************************************************************** end of code by Madhu 17.12.2013
* ENDIF.
* ENDIF.
ENDIF.
I have attached the process_item complete code.
12-18-2013 4:47 AM
The best option would be to put a break point with the "mmpur_message_forced 'E' 'ME' '563' '' '' '' ''. in the T04 system since int works in the parent system it would be hard to identify the reason.
Also check the message class also to ensure the same is available in taget system.
Hope it helps.
12-18-2013 5:07 AM
Hi,
Have you check the all conditions in ME21N. Put the break point check once again. I did not find any thing wrong in the coding.
IF ( sy-tcode = 'ME21N' OR sy-tcode = 'ME22N' ) and
re_hdrdata-ekorg = '0001' AND
re_data-pstyp NE '7' and " can you check this
re_data-mwskz IS INITIAL and
re_data-LOEKZ eq ''. " can you check this
mmpur_metafield mmmfd_tax_code.
mmpur_message_forced 'E' 'ME' '563' '' '' '' ''.
endif.
12-18-2013 5:13 AM
Hiiii,
what do you mean here by E04 & T04 systems?
many thanks / Himanshu gupta
12-18-2013 5:26 AM
Please read the documentation for understanding about meta fields and do accordingly by forcing message via meta fields.
Nabheet
12-18-2013 6:01 AM