Ever wonder where to hard code your text ? I mean not within your program but in another place where you can call them? useful for pdf/email and etc
Recently found out from my colleague that we could use transaction
so10 (standard text) where we could create the text and import them using function call
"Retrieve email template in ITF format
CALL FUNCTION 'READ_TEXT'
EXPORTING
ID = 'ST'
LANGUAGE = SY-LANGU
NAME = I_TEMPLATE_NAME
OBJECT = 'TEXT'
IMPORTING
HEADER = LS_HEADER
TABLES
LINES = LT_EMAIL_TEMPLATE_RAW
EXCEPTIONS
ID = 1
LANGUAGE = 2
NAME = 3
NOT_FOUND = 4
OBJECT = 5
REFERENCE_CHECK = 6
WRONG_ACCESS_TO_ARCHIVE = 7
OTHERS = 8.
IF SY-SUBRC <> 0.
EXIT. "No email to be sent
ENDIF.
Thanks to Mohd Khairil B Markom
Post a Comment