Short text
Field symbol has not yet been assigned.
发生了什么?
Error in the ABAP Application Program
The current ABAP program "CL_GUI_ALV_GRID===============CP" had to be
terminated because it has
come across a statement that unfortunately cannot be executed.
错误分析
You attempted to access an unassigned field symbol
(data segment 32781).
This error may occur if
- You address a typed field symbol before it has been set with
ASSIGN
- You address a field symbol that pointed to the line of an
internal table that was deleted
- You address a field symbol that was previously reset using
UNASSIGN or that pointed to a local field that no
longer exists
- You address a global function interface, although the
respective function module is not active - that is, is
not in the list of active calls. The list of active calls
can be taken from this short dump.
程序如下:
FORM listado .
g_repid = sy-repid.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = g_repid
is_layout = gs_layout
it_fieldcat = gt_fieldcat[]
i_save = 'A'
it_events = git_events[]
i_callback_pf_status_set = 'FRM_STATUS' "显示自定义toolbar
i_callback_user_command = 'USER_COMMAND' "调用命令
it_sort = it_sort[]
TABLES
t_outtab = “《- 动态内表
EXCEPTIONS
program_error = 1
OTHERS = 2.
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. " LISTADO
FORM save_data .
DATA: l_grid TYPE REF TO cl_gui_alv_grid.
*------------将ALV上修改的内容保存到内表---------------------------------*
CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'
IMPORTING
e_grid = l_grid.
CALL METHOD l_grid->check_changed_data. ”
ENDFORM. " SAVE_DATA
dat = sy-datum + n.
CLEAR gt_fieldcat.
gt_fieldcat-fieldname = dat.
gt_fieldcat-seltext_s = dat.
gt_fieldcat-outputlen = 12.
gt_fieldcat-edit = 'X'.
gt_fieldcat-inttype = t_tab1-psmng.
gt_fieldcat-seltext_m = gt_fieldcat-seltext_s.
gt_fieldcat-seltext_l = gt_fieldcat-seltext_s.
APPEND gt_fieldcat.
n = n + 1.