Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

GUI_UPLOAD

Former Member
0 Kudos

Hi,

I want to upload five different tab delimited text file to the respective internal tables. The obvious way to do this is using GUI_UPLOAD function for each and every text file. Is it possible to perform this by using GUI_UPLOAD only once in an subroutine and calling the subroutine five times by passing the internal table name and the file name? Or suggest me is there any other way?

Regards,

Arokiaraj. S

3 REPLIES 3

andreas_mann3
Active Contributor
0 Kudos

hi,

1) collect your itabs in an int.table ztab

2) loop ztab

a) gui_uplod (e.g. with filename = tabname)

b) do your processing

...

-> example for download:

SELECT TABNAME devclass FROM  INFO_TABL INTO TABLE itab
         WHERE  TABNAME IN TABN
         AND    DEVCLASS = DEVC
         AND    tabclass = 'TRANSP'.

  LOOP AT itab.
  
  create data dyn_tab type standard table of (itab-tabn).
  assign dyn_tab->* to <dyn_tab>.

  SELECT * FROM (itab-TABN) INTO table <dyn_tab>.

  CALL FUNCTION 'GUI_DOWNLOAD'
       EXPORTING
            filetype = 'ASC'
            filename = filename
       TABLES
            data_tab = <dyn_tab>.


  endloop.

regards Andreas

jayanthi_jayaraman
Active Contributor
0 Kudos

Hi,

You can do that by passing filename and data_tab[internal table] to the subrotine.your datatab should be passed as changing parameter.

Former Member
0 Kudos

Hi,

yes i guess u can do that:

PERFORM f100_upload_data USING file name

CHANGING internal table.

Regards,

Anjali.