메뉴 건너뛰기

SAP 한국 커뮤니티



 


1) 사용 function
  DYNP_VALUES_READ


2) 사용방법
 call function 'DYNP_VALUES_READ'
       exporting
            dyname     = 'SAPMZA22'         " 화면이 소속된 프로그램 명
            dynumb     = sy-dynnr           " 화면 번호
       tables
            dynpfields = fld_value          " export : 읽어들일 필드 명
                                             " import : 준 필드 명의 값
       exceptions
            others     = 01.


*&---------------------------------------------------------------------*
*&      Form  DYNP_VALUES_READ
*&---------------------------------------------------------------------*
*       text                                                           *
*----------------------------------------------------------------------*
*  -->  FNAME     Field Name
*  <--  RETCD     Return Code
*----------------------------------------------------------------------*
form dynp_values_read using value(fname) like dynpread-fieldname
                            retcd like sy-subrc.
  refresh fld_value.
  clear   fld_value.
  fld_value-fieldname = fname.
  append fld_value.


*------- 현재 화면의 특정 필드 값 읽기
  call function 'DYNP_VALUES_READ'
       exporting
            dyname     = 'SAPMZA22'
            dynumb     = sy-dynnr
       tables
            dynpfields = fld_value
       exceptions
            others     = 01.
  retcd = sy-subrc.
endform.                               " DYNP_VALUES_READ


3) 데이터 정의
data : begin of fld_value occurs 1.
        include structure dynpread.
data : end of fld_value.


FIELDNAME                        C30
STEPL                            I4
FIELDVALUE                       C132
FIELDINP                         C1


* 썬님에 의해서 게시물 이동되었습니다 (2010-04-02 11:37)