F4TOOL_F4FUNCTION_BRIDGE 펑션 관련 소스는 없는거 같아서
살짝 공부 하면서 만들어 보았습니다. ^^ 즐밥하세효오오~
*&---------------------------------------------------------------------*
*& Report YKDNTEST19
*&
*&---------------------------------------------------------------------*
*&
*&
*&---------------------------------------------------------------------*
REPORT YKDNTEST19.
TABLES : SFLIGHT.
TYPE-POOLS: F4TYP.
PARAMETERS : TTT TYPE SFLIGHT-CARRID NO-DISPLAY.
SELECT-OPTIONS TEST FOR TTT.
DATA : TL_SFLIGHT TYPE TABLE OF SFLIGHT,
SL_SFLIGHT LIKE LINE OF TL_SFLIGHT.
DATA : LT_FIELDS LIKE TABLE OF HELP_VALUE WITH HEADER LINE,
LT_VALUES LIKE TABLE OF DF14VD-NAME WITH HEADER LINE.
DATA : LT_HEADING TYPE TABLE OF F4TYP_HEAD_STRUC WITH HEADER LINE.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR TEST-LOW.
SELECT * INTO CORRESPONDING FIELDS OF TABLE TL_SFLIGHT FROM SFLIGHT.
LT_FIELDS-TABNAME = 'SFLIGHT'.
LT_FIELDS-FIELDNAME = 'CARRID'.
LT_FIELDS-SELECTFLAG = 'X'.
APPEND LT_FIELDS.
LT_FIELDS-TABNAME = 'SFLIGHT'.
LT_FIELDS-FIELDNAME = 'SEATSMAX'.
LT_FIELDS-SELECTFLAG = SPACE.
APPEND LT_FIELDS.
LOOP AT TL_SFLIGHT INTO SL_SFLIGHT.
LT_VALUES = SL_SFLIGHT-CARRID. APPEND LT_VALUES.
LT_VALUES = SL_SFLIGHT-SEATSMAX. APPEND LT_VALUES.
ENDLOOP.
CALL FUNCTION 'F4TOOL_F4FUNCTION_BRIDGE'
EXPORTING
* CUCOL = 0
* CUROW = 0
TABNAME = SPACE
FIELDNAME = SPACE
DISPLAY_ONLY = SPACE
* NO_CONVERSION = ' '
* WINDOW_TITLE =
* TABDISPLAY = ' '
IMPORTING
SELECTED_VALUE = TEST-LOW
* SELECTED_INDEX =
TABLES
* SHVALUE_TAB =
* SHSTRUC_TAB =
VALUE_TAB = LT_VALUES
FIELDS_TAB = LT_FIELDS
* VALUES_OUT =
* COLTITLE_TAB = LT_HEADING
* SEL_OPT =
.
CLEAR : LT_VALUES[], LT_FIELDS[].
START-OF-SELECTION.
아하~ 이런 방법도 있네요...
좋은 샘플 고맙습니다...