SAP R/3

How to download internal table to PC file in ABAP/4

When you want to download internal table to PC file in ABAP/4, you can apply function module "WS_DOWNLOAD".

Example


CALL FUNCTION ’WS_DOWNLOAD’
      EXPORTING
           FILENAME               = LV_TEXT "PC File Name and Location
           FILETYPE               = ’DAT’
      TABLES
           DATA_TAB               = I_MESG "Internal Table
      EXCEPTIONS
           FILE_OPEN_ERROR        = 1
           FILE_WRITE_ERROR       = 2
           INVALID_FILESIZE       = 3
           INVALID_TYPE           = 4
           NO_BATCH               = 5
           UNKNOWN_ERROR          = 6
           INVALID_TABLE_WIDTH    = 7
           GUI_REFUSE_FILETRANSFER = 8
           CUSTOMER_ERROR         = 9
           OTHERS                 = 10.

How to get name of day by Date in ABAP/4

When you want to get name of day by using date in ABAP/4, you can apply function module "DATE_TO_DAY".

Example


*&---------------------------------------------------------------------*
*&     Form get_name_of_day
*&---------------------------------------------------------------------*
FORM get_name_of_day USING   PAR_DATUM
                    CHANGING PAR_DAY_NAME.
clear par_day_name.
CALL FUNCTION ’DATE_TO_DAY’
   EXPORTING
     DATE         = par_datum
   IMPORTING
     WEEKDAY      = par_day_name
           .

How to get long text in ABAP/4

When you want to retrieve the data that record in long text on selected document for show in ABAP report, you can apply function module "READ_TEXT".

Example


DATA: I_LINE  LIKE TLINE OCCURS 0 WITH HEADER LINE.
     CALL FUNCTION ’READ_TEXT’
          EXPORTING
               ID                   = ’Z002’
               LANGUAGE             = SY-LANGU
               NAME                 = LV_NAME
               OBJECT               = ’VBBK’
          TABLES
               LINES                = I_LINE "Long text
          EXCEPTIONS
               ID                   = 1
               LANGUAGE             = 2
               NAME                 = 3
               NOT_FOUND            = 4
               OBJECT               = 5
               REFERENCE_CHECK      = 6
               WRONG_ACCESS_TO_ARCHIVE = 7
               OTHERS               = 8.

Standard Tag Column in SAPscript

Format     Description
* Default paragraph
Blank Continuous text

= Extended line
( Raw line
/ Line feed
/= Line feed and extended line
/( Line feed and raw line
/: Command line
/* Comment line
/E Text element

Formatting Options in SAPscript: Ignore Conversion Routine

In SAPscript, you can ignore conversion routines of this symbol by this option.

Syntax


&VAR(K)&