05-11-2015 4:26 PM
Hi Folks,
I have to update the long text in operations tab of IW31 work order screen using ABAP code. Please tell me if it can be done by using FM BAPI_ALM_ORDER_MAINTAIN. If yes then what all fields to be passed? If no, then what is the alternate solution. Thanks.
05-11-2015 5:30 PM
You need use the tables ET_TEXTS and ET_TEXT_LINES to populate the text.
Things to remember:
ls_text_h-orderid = P_ORDER.
ls_text_h-langu = sy-langu.
ls_text_h-textstart = 1.
ls_text_h-textend = n_text_end.
APPEND ls_text_h TO t_text_h.
* Move text
ls_text-tdline = e_txt_editor-tdline.
APPEND ls_text TO t_text.
CALL FUNCTION 'BAPI_ALM_ORDER_GET_DETAIL'
EXPORTING
number = pa_aufnr
IMPORTING
es_header = e_head_e
TABLES
et_operations = t_oper_e[]
et_components = t_comp_e[]
et_texts = t_text_h[]
et_text_lines = t_text[]
return = t_return[].
Regards,
Naimesh Patel