SAP Function Modules

TB_LIMIT_UPLOAD SAP Function module - File Transfer of File on Presentation Server to Internal Table with Dial







TB_LIMIT_UPLOAD is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.

See here to view full function module documentation and code listing, simply by entering the name TB_LIMIT_UPLOAD into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: TBLF
Released Date: Not Released
Processing type: Normal fucntion module
Normal function module settings


Pattern for FM TB_LIMIT_UPLOAD - TB LIMIT UPLOAD





CALL FUNCTION 'TB_LIMIT_UPLOAD' "File Transfer of File on Presentation Server to Internal Table with Dialog
* EXPORTING
*   filename = SPACE            " any           Name of the File (Default Value)
*   filetype = SPACE            " rlgrap-filetype  File Type (ASCII, Binary, ...)(Default Value)
*   item = SPACE                " any           Header for File Dialog
*   filemask_mask = SPACE       " any
  IMPORTING
    filesize =                  " any           Number of Bytes Transferred
    cancel =                    " any           Is Set on 'Cancel'
    act_filename =              " any           Name of the File (Entered Value)
    act_filetype =              " rlgrap-filetype  File Type (Entered Value)
  TABLES
    data_tab =                  "               Transfer Table
  EXCEPTIONS
    INVALID_TYPE = 1            "               Invalid Value for Parameter FILETYPE
    NO_BATCH = 2                "               Front-End Function Cannot Be Executed in Batch
    UNKNOWN_ERROR = 3           "               Not Used
    GUI_REFUSE_FILETRANSFER = 4  "              Incorrect Front End, or Error in Front End
    NO_AUTHORITY = 5            "               No Upload Authorization
    .  "  TB_LIMIT_UPLOAD

ABAP code example for Function Module TB_LIMIT_UPLOAD





The ABAP code below is a full code listing to execute function module TB_LIMIT_UPLOAD including all data declarations. The code uses the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the original method of declaring data variables up front. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8).

DATA:
ld_filesize  TYPE ANY ,
ld_cancel  TYPE ANY ,
ld_act_filename  TYPE ANY ,
ld_act_filetype  TYPE RLGRAP-FILETYPE ,
it_data_tab  TYPE STANDARD TABLE OF STRING,"TABLES PARAM
wa_data_tab  LIKE LINE OF it_data_tab .

DATA(ld_filename) = 'Check type of data required'.

DATA(ld_filetype) = some text here
DATA(ld_item) = 'Check type of data required'.
DATA(ld_filemask_mask) = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_data_tab to it_data_tab. . CALL FUNCTION 'TB_LIMIT_UPLOAD' * EXPORTING * filename = ld_filename * filetype = ld_filetype * item = ld_item * filemask_mask = ld_filemask_mask IMPORTING filesize = ld_filesize cancel = ld_cancel act_filename = ld_act_filename act_filetype = ld_act_filetype TABLES data_tab = it_data_tab EXCEPTIONS INVALID_TYPE = 1 NO_BATCH = 2 UNKNOWN_ERROR = 3 GUI_REFUSE_FILETRANSFER = 4 NO_AUTHORITY = 5 . " TB_LIMIT_UPLOAD
IF SY-SUBRC EQ 0. "All OK ELSEIF SY-SUBRC EQ 1. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 2. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 3. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 4. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 5. "Exception "Add code for exception here ENDIF.







ABAP code to compare 7.40 inline data declaration with original syntax

The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.

DATA:
ld_filesize  TYPE ANY ,
ld_filename  TYPE ANY ,
it_data_tab  TYPE STANDARD TABLE OF STRING ,
wa_data_tab  LIKE LINE OF it_data_tab,
ld_cancel  TYPE ANY ,
ld_filetype  TYPE RLGRAP-FILETYPE ,
ld_act_filename  TYPE ANY ,
ld_item  TYPE ANY ,
ld_act_filetype  TYPE RLGRAP-FILETYPE ,
ld_filemask_mask  TYPE ANY .

ld_filename = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_data_tab to it_data_tab.

ld_filetype = some text here
ld_item = 'Check type of data required'.
ld_filemask_mask = 'Check type of data required'.

SAP Documentation for FM TB_LIMIT_UPLOAD


Data in a file on the presentation server is transferred to an internal table. ...See here for full SAP fm documentation














Contribute (Add Comments)

Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name TB_LIMIT_UPLOAD or its description.