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.
cancel
Showing results for 
Search instead for 
Did you mean: 

how to make item text mandatory in me51n tcode .

Former Member
0 Kudos

hello experts,

i developed this code , but it is not working , please suggest me wat i did mistake in my code.....

*data : it_lines1 type tline occurs 0 with header line .

*data :tdname like stxh-tdname.

**

*

*loop at im_t_eban1.

*

  • if im_t_eban1-werks = '3000'.

  • if sy-tcode = 'ME51N'.

*

  • concatenate im_t_eban1-banfn im_t_eban1-bnfpo into tdname.

*

*

  • call function 'READ_TEXT'

  • exporting

  • client = sy-mandt

  • id = 'B01'

  • language = 'E'

  • name = tdname

  • object = 'EBAN'

  • tables

  • lines = it_lines1.

*

*

*

  • loop at it_lines1 .

*

  • if it_lines1-tdline is initial.

*

*

*

  • if sy-subrc <> 0.

  • ex_mes1-type = 'E'.

  • ex_mes1-id = 'ZMM_MSG'.

  • ex_mes1-number = '063'.

  • append ex_mes1.

  • ex_messages[] = ex_mes1[].

  • clear ex_mes1.

  • free ex_mes1.

  • endif.

  • endif.

*

*

  • endloop.

*

  • endif.

  • endif.

*

*endloop.

note: here no 63 is message no ,( please enter item text).

2 REPLIES 2

karthik_vardhan
Explorer
0 Kudos

Hi,

Message e63(ZMM_MSG) .

Try This .

in place of

*ex_mes1-type = 'E'.

  • ex_mes1-id = 'ZMM_MSG'.

  • ex_mes1-number = '063'.

  • append ex_mes1.

  • ex_messages] = ex_mes1[.

  • clear ex_mes1.

  • free ex_mes1.

Former Member
0 Kudos

Hi Kamal

Kindly where you used this code ,in which enhancement ? ,because i need to do the same

Regards

Ghadeer