cancel
Showing results for 
Search instead for 
Did you mean: 

Control Header Text edit functionality

former_member184028
Participant
0 Kudos

Hello All,

We have one requirement, where we want to have control on PO header text .

1. Make Existing Text in Header text no editable

2. Users can append new text, but should not be able to modify/delete the existing text in PO header text.

any idea on how to achieve same using ABAP, if anyone implemented same plz share your ideas.

Accepted Solutions (1)

Accepted Solutions (1)

satyapriyanka_vana
Active Participant
0 Kudos

Hi,

Implement BADI ME_PROCESS_PO_CUST. Place the below code in the method 'OPEN'.


SPAN {
font-family: "Courier New";
font-size: 10pt;
color: #000000;
background: #FFFFFF;
}
.L0S33 {
color: #4DA619;
}
.L0S52 {
color: #0000FF;
}
.L0S55 {
color: #800080;
}
.L0S70 {
color: #808080;
}

METHOD if_ex_me_process_po_cust~open.

  DATA : lv_id TYPE tdid,

       it_lines TYPE STANDARD TABLE OF mmpur_textlines,

       w_lines LIKE LINE OF it_lines,

       lv_tformat TYPE mmpur_bool.

  lv_id = 'F16'.

  CALL METHOD im_header->if_longtexts_mm~get_text

    EXPORTING

      im_tdid           = lv_id

    IMPORTING

      ex_textlines      = it_lines

      ex_text_formatted = lv_tformat.



  LOOP AT it_lines INTO w_lines WHERE tdline IS NOT INITIAL.

    w_lines-tdformat = '>X'.

    CONCATENATE '*' w_lines-tdline INTO w_lines-tdline SEPARATED BY space.

    MODIFY it_lines FROM w_lines INDEX sy-tabix.

  ENDLOOP.



  CALL METHOD im_header->if_longtexts_mm~set_text

    EXPORTING

      im_tdid      = lv_id

      im_textlines = it_lines.

ENDMETHOD.

Hope it helps.

Regards,

Priyanka.

Answers (0)