SAP Function Modules

SSF_READ_STYLE_ALL_VARIANTS SAP Function module







SSF_READ_STYLE_ALL_VARIANTS 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 SSF_READ_STYLE_ALL_VARIANTS into the relevant SAP transaction such as SE37 or SE80.

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


Pattern for FM SSF_READ_STYLE_ALL_VARIANTS - SSF READ STYLE ALL VARIANTS





CALL FUNCTION 'SSF_READ_STYLE_ALL_VARIANTS' "
  EXPORTING
    i_style_name =              " tdssname
    i_style_active_flag =       " tdactivate
*   i_style_language = SY-LANGU  " tdspras
  TABLES
    e_headers =                 " ssfcats
*   e_paragraphs =              " ssfparas
*   e_strings =                 " ssfstrings
*   e_tabstops =                " stxstab
  EXCEPTIONS
    NO_NAME = 1                 "
    NO_STYLE = 2                "
    ACTIVE_STYLE_NOT_FOUND = 3  "
    INACTIVE_STYLE_NOT_FOUND = 4  "
    NO_MAIN_VARIANT = 5         "
    CANCELLED = 6               "
    NO_ACCESS_PERMISSION = 7    "
    .  "  SSF_READ_STYLE_ALL_VARIANTS

ABAP code example for Function Module SSF_READ_STYLE_ALL_VARIANTS





The ABAP code below is a full code listing to execute function module SSF_READ_STYLE_ALL_VARIANTS 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:
it_e_headers  TYPE STANDARD TABLE OF SSFCATS,"TABLES PARAM
wa_e_headers  LIKE LINE OF it_e_headers ,
it_e_paragraphs  TYPE STANDARD TABLE OF SSFPARAS,"TABLES PARAM
wa_e_paragraphs  LIKE LINE OF it_e_paragraphs ,
it_e_strings  TYPE STANDARD TABLE OF SSFSTRINGS,"TABLES PARAM
wa_e_strings  LIKE LINE OF it_e_strings ,
it_e_tabstops  TYPE STANDARD TABLE OF STXSTAB,"TABLES PARAM
wa_e_tabstops  LIKE LINE OF it_e_tabstops .

DATA(ld_i_style_name) = 'Check type of data required'.
DATA(ld_i_style_active_flag) = 'Check type of data required'.
DATA(ld_i_style_language) = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_e_headers to it_e_headers.

"populate fields of struture and append to itab
append wa_e_paragraphs to it_e_paragraphs.

"populate fields of struture and append to itab
append wa_e_strings to it_e_strings.

"populate fields of struture and append to itab
append wa_e_tabstops to it_e_tabstops. . CALL FUNCTION 'SSF_READ_STYLE_ALL_VARIANTS' EXPORTING i_style_name = ld_i_style_name i_style_active_flag = ld_i_style_active_flag * i_style_language = ld_i_style_language TABLES e_headers = it_e_headers * e_paragraphs = it_e_paragraphs * e_strings = it_e_strings * e_tabstops = it_e_tabstops EXCEPTIONS NO_NAME = 1 NO_STYLE = 2 ACTIVE_STYLE_NOT_FOUND = 3 INACTIVE_STYLE_NOT_FOUND = 4 NO_MAIN_VARIANT = 5 CANCELLED = 6 NO_ACCESS_PERMISSION = 7 . " SSF_READ_STYLE_ALL_VARIANTS
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 ELSEIF SY-SUBRC EQ 6. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 7. "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_i_style_name  TYPE TDSSNAME ,
it_e_headers  TYPE STANDARD TABLE OF SSFCATS ,
wa_e_headers  LIKE LINE OF it_e_headers,
ld_i_style_active_flag  TYPE TDACTIVATE ,
it_e_paragraphs  TYPE STANDARD TABLE OF SSFPARAS ,
wa_e_paragraphs  LIKE LINE OF it_e_paragraphs,
ld_i_style_language  TYPE TDSPRAS ,
it_e_strings  TYPE STANDARD TABLE OF SSFSTRINGS ,
wa_e_strings  LIKE LINE OF it_e_strings,
it_e_tabstops  TYPE STANDARD TABLE OF STXSTAB ,
wa_e_tabstops  LIKE LINE OF it_e_tabstops.

ld_i_style_name = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_e_headers to it_e_headers.
ld_i_style_active_flag = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_e_paragraphs to it_e_paragraphs.
ld_i_style_language = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_e_strings to it_e_strings.

"populate fields of struture and append to itab
append wa_e_tabstops to it_e_tabstops.

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 SSF_READ_STYLE_ALL_VARIANTS or its description.