2016 Jul 05 12:23 PM
Hi all,
ABAP newbie here, so excuse the silly questions.
This code calls the GUI_UPLOAD function and stores the the values from a csv file into table type i_load.
My thought is that this table should be globally defined so I can access its contents from another function module that will read records.
FUNCTION YMSEN_DEMO.
*"----------------------------------------------------------------------
*"*"Local Interface:
*"----------------------------------------------------------------------
call function 'GUI_UPLOAD'
exporting
filename = 'c:\temp\infile.csv'
tables
data_tab = i_load.
if sy-subrc <> 0.
message s368(00) with 'Unable to read file'.
stop.
endif.
ENDFUNCTION.
So in my program I defined the table as such
*&---------------------------------------------------------------------*
*& Module Pool YMSEN_DEMO
*&
*&---------------------------------------------------------------------*
*&
*&
*&---------------------------------------------------------------------*
include ymsen_demotop . " global Data
* INCLUDE YMSEN_DEMOO01 . " PBO-Modules
include ymsen_demoi01 . " PAI-Modules
* INCLUDE YMSEN_DEMOF01 . " FORM-Routines
data: i_load type table of ymsen_t_load.
But when I activate everything I get an error
Field I_load is unknown. It is neither in one of the specified tables nor defined by a "DATA" statement.
2016 Jul 05 12:41 PM
Define the data in the top include of the function group, not in the caller program...
(some LyfunctiongroupTOP include)
Hint: Try to double-click the field in the source and follow pop-up guide. (Also re-read your course material)
Regards,
Raymond
2016 Jul 05 12:41 PM
Define the data in the top include of the function group, not in the caller program...
(some LyfunctiongroupTOP include)
Hint: Try to double-click the field in the source and follow pop-up guide. (Also re-read your course material)
Regards,
Raymond
2016 Jul 05 12:47 PM
*&---------------------------------------------------------------------*
*& Include YMSEN_DEMOTOP Module Pool YMSEN_DEMO
*&
*&---------------------------------------------------------------------*
PROGRAM YMSEN_DEMO.
data: i_load type table of ymsen_t_load.
after tranfering the variable to the top include the problem is the same
2016 Jul 05 12:52 PM