07-25-2012 7:59 PM
I have created a copy of SAP code and am trying to add static text to an email title. I don't have much ABAP experience so please bear with me. I am trying to modify the code below to add a bit of static text before the dynamic elements, but I'm not really sure how to do so.
REPLACE '&' WITH ls_orderadm_h-object_id
INTO ls_output_options-tdtitle.
I think that is the place, but here is the whole snippet of code in case I am looking in the wrong spot.
* set mail title
SELECT SINGLE caption INTO ls_output_options-tdtitle
FROM stxfadmt WHERE
formname = ip_smart_form AND
langu = lv_language.
IF ls_output_options-tdtitle IS INITIAL.
SELECT SINGLE caption INTO ls_output_options-tdtitle
FROM stxfadmt WHERE
formname = ip_smart_form.
ENDIF.
REPLACE '&' WITH ls_orderadm_h-object_id
INTO ls_output_options-tdtitle.
Thanks!
07-25-2012 8:06 PM
If ls_output_options-tdtitle is being passed to the email title, then you
CONCATENATE statictext ls_output_options-tdtitle INTO ls_output_options-tdtitle.
Make sure the size of the data after concatenation does not exceed the variable
- Puneet
07-25-2012 8:06 PM
If ls_output_options-tdtitle is being passed to the email title, then you
CONCATENATE statictext ls_output_options-tdtitle INTO ls_output_options-tdtitle.
Make sure the size of the data after concatenation does not exceed the variable
- Puneet
07-25-2012 8:19 PM
Puneet,
Thanks! This may be a stupid question, but I'm assuming that CONCATENATE would go after the
INTO ls_output_options-tdtitle that is already there?
Regards,
Jon
07-25-2012 9:23 PM
Yes that is correct. I will go after the REPLACE statement that you have.
REPLACE '&' WITH ls_orderadm_h-object_id
INTO ls_output_options-tdtitle.CONCATENATE ls_statictext ls_output_options-tdtitle INTO ls_output_options-tdtitle SEPARATED BY SPACE.