Hi Guys,
I am trying to append text lines into a particular NOTES section in Webui. Here is what i am using in my code,
DATA: lr_ent1 TYPE REF TO cl_crm_bol_entity,
lr_texts TYPE REF TO cl_crm_bol_entity,
lr_result TYPE REF TO cl_crm_bol_entity.
DATA: lv_lines TYPE string,
lv_note TYPE string,
lv_tdid TYPE string.
lr_ent1 = lr_adminh.
lr_ent1 = lr_ent1->get_related_entity( iv_relation_name = 'BTHeaderTextSet' ).
IF lr_ent1 IS BOUND.
lr_ent1 = lr_ent1->get_related_entity( iv_relation_name = 'BTTextHAll' ).
IF lr_ent1 IS BOUND.
lv_note = 'Blah Blah Blah'.
IF lr_ent1->switch_to_change_mode( ) EQ abap_true.
lv_tdid = lr_ent1->if_bol_bo_property_access~get_property_as_string( iv_attr_name = 'TDID' ).
IF lv_tdid = 'ZABC'.
lr_ent1->if_bol_bo_property_access~set_property( iv_attr_name = 'CONC_LINES'
iv_value = lv_note ).
ENDIF.
ENDIF.
ENDIF.
ENDIF.
lr_core->modify( ).
The problem here is, I wanted to add text for a particular text id, 'ZABC' but its adding text for the first available text id. Is there a way I could mention the text id along with the lines