REPORT z_barry_mod_sel_text.
TABLES mara.
PARAMETER p_test(10).
SELECT-OPTIONS: s_test FOR mara-matnr ,
s_matnr FOR mara-matnr .
*INITIALIZATION.
AT SELECTION-SCREEN OUTPUT.
PERFORM mod_sel_text USING sy-repid 'P' 'P_TEST' 'P类型测试'.
PERFORM mod_sel_text USING sy-repid 'S' 'S_TEST' 'S类型测试'.
*&---------------------------------------------------------------------*
*& FORM MOD_SEL_TEXT
*&---------------------------------------------------------------------*
FORM mod_sel_text USING p_repid kind parameter text .
DATA sel TYPE rsseltexts OCCURS 1 WITH HEADER LINE.
REFRESH sel.
sel-name = parameter.
sel-kind = kind.
sel-text = text.
APPEND sel.
CALL FUNCTION 'SELECTION_TEXTS_MODIFY'
EXPORTING
program = p_repid
TABLES
seltexts = sel
EXCEPTIONS
program_not_found = 1
program_cannot_be_generated = 2
OTHERS = 3.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
ENDFORM. "MOD_SEL_TEXT
或者:
REPORT z_barry_test.
PARAMETERS: p_test(20).
AT SELECTION-SCREEN OUTPUT .
%_p_test_%_app_%-text = p_test.
阅读(742) | 评论(0) | 转发(0) |