SAP LT_VARIANT_LOAD Function Module for









LT_VARIANT_LOAD is a standard lt variant load SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used to perform a specific ABAP function and below is the pattern details, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.


See here to view full function module documentation and code listing for lt variant load FM, simply by entering the name LT_VARIANT_LOAD into the relevant SAP transaction such as SE37 or SE38.

Function Group: SKBS
Program Name: SAPLSKBS
Main Program: SAPLSKBS
Appliation area: S
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function LT_VARIANT_LOAD pattern details

In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.
CALL FUNCTION 'LT_VARIANT_LOAD'"
EXPORTING
* I_TOOL = 'LT' "
I_TABNAME = "
* I_TABNAME_SLAVE = "
* I_DIALOG = 'X' "
* I_USER_SPECIFIC = ' ' "
* I_DEFAULT = 'X' "
* I_NO_REPTEXT_OPTIMIZE = "
* I_VIA_GRID = "
* I_FCAT_COMPLETE = "

IMPORTING
E_EXIT = "
ET_FIELDCAT = "
ET_SORT = "
ET_FILTER = "

CHANGING
CS_LAYOUT = "
CT_DEFAULT_FIELDCAT = "
CS_VARIANT = "

EXCEPTIONS
WRONG_INPUT = 1 FC_NOT_COMPLETE = 2 NOT_FOUND = 3
.



IMPORTING Parameters details for LT_VARIANT_LOAD

I_TOOL -

Data type: LTDX-RELID
Default: 'LT'
Optional: Yes
Call by Reference: No ( called with pass by value option)

I_TABNAME -

Data type: KKBLO_TABNAME
Optional: No
Call by Reference: No ( called with pass by value option)

I_TABNAME_SLAVE -

Data type: KKBLO_TABNAME
Optional: Yes
Call by Reference: No ( called with pass by value option)

I_DIALOG -

Data type: C
Default: 'X'
Optional: Yes
Call by Reference: No ( called with pass by value option)

I_USER_SPECIFIC -

Data type: C
Default: ' '
Optional: Yes
Call by Reference: No ( called with pass by value option)

I_DEFAULT -

Data type: C
Default: 'X'
Optional: Yes
Call by Reference: No ( called with pass by value option)

I_NO_REPTEXT_OPTIMIZE -

Data type: C
Optional: Yes
Call by Reference: No ( called with pass by value option)

I_VIA_GRID -

Data type: CHAR01
Optional: Yes
Call by Reference: No ( called with pass by value option)

I_FCAT_COMPLETE -

Data type: ABAP_BOOL
Optional: Yes
Call by Reference: Yes

EXPORTING Parameters details for LT_VARIANT_LOAD

E_EXIT -

Data type: C
Optional: No
Call by Reference: No ( called with pass by value option)

ET_FIELDCAT -

Data type: KKBLO_T_FIELDCAT
Optional: No
Call by Reference: No ( called with pass by value option)

ET_SORT -

Data type: KKBLO_T_SORTINFO
Optional: No
Call by Reference: No ( called with pass by value option)

ET_FILTER -

Data type: KKBLO_T_FILTER
Optional: No
Call by Reference: No ( called with pass by value option)

CHANGING Parameters details for LT_VARIANT_LOAD

CS_LAYOUT -

Data type: KKBLO_LAYOUT
Optional: No
Call by Reference: No ( called with pass by value option)

CT_DEFAULT_FIELDCAT -

Data type: KKBLO_T_FIELDCAT
Optional: No
Call by Reference: No ( called with pass by value option)

CS_VARIANT -

Data type: DISVARIANT
Optional: No
Call by Reference: No ( called with pass by value option)

EXCEPTIONS details

WRONG_INPUT -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

FC_NOT_COMPLETE -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

NOT_FOUND -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

Copy and paste ABAP code example for LT_VARIANT_LOAD Function Module

The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than 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 newer method of declaring data variables on the fly. 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), which i why i have stuck to the origianl for this example.

DATA:
lv_e_exit  TYPE C, "   
lv_i_tool  TYPE LTDX-RELID, "   'LT'
lv_cs_layout  TYPE KKBLO_LAYOUT, "   
lv_wrong_input  TYPE KKBLO_LAYOUT, "   
lv_i_tabname  TYPE KKBLO_TABNAME, "   
lv_et_fieldcat  TYPE KKBLO_T_FIELDCAT, "   
lv_fc_not_complete  TYPE KKBLO_T_FIELDCAT, "   
lv_ct_default_fieldcat  TYPE KKBLO_T_FIELDCAT, "   
lv_et_sort  TYPE KKBLO_T_SORTINFO, "   
lv_not_found  TYPE KKBLO_T_SORTINFO, "   
lv_cs_variant  TYPE DISVARIANT, "   
lv_i_tabname_slave  TYPE KKBLO_TABNAME, "   
lv_i_dialog  TYPE C, "   'X'
lv_et_filter  TYPE KKBLO_T_FILTER, "   
lv_i_user_specific  TYPE C, "   ' '
lv_i_default  TYPE C, "   'X'
lv_i_no_reptext_optimize  TYPE C, "   
lv_i_via_grid  TYPE CHAR01, "   
lv_i_fcat_complete  TYPE ABAP_BOOL. "   

  CALL FUNCTION 'LT_VARIANT_LOAD'  "
    EXPORTING
         I_TOOL = lv_i_tool
         I_TABNAME = lv_i_tabname
         I_TABNAME_SLAVE = lv_i_tabname_slave
         I_DIALOG = lv_i_dialog
         I_USER_SPECIFIC = lv_i_user_specific
         I_DEFAULT = lv_i_default
         I_NO_REPTEXT_OPTIMIZE = lv_i_no_reptext_optimize
         I_VIA_GRID = lv_i_via_grid
         I_FCAT_COMPLETE = lv_i_fcat_complete
    IMPORTING
         E_EXIT = lv_e_exit
         ET_FIELDCAT = lv_et_fieldcat
         ET_SORT = lv_et_sort
         ET_FILTER = lv_et_filter
    CHANGING
         CS_LAYOUT = lv_cs_layout
         CT_DEFAULT_FIELDCAT = lv_ct_default_fieldcat
         CS_VARIANT = lv_cs_variant
    EXCEPTIONS
        WRONG_INPUT = 1
        FC_NOT_COMPLETE = 2
        NOT_FOUND = 3
. " LT_VARIANT_LOAD




ABAP code using 7.40 inline data declarations to call FM LT_VARIANT_LOAD

The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8.

 
"SELECT single RELID FROM LTDX INTO @DATA(ld_i_tool).
DATA(ld_i_tool) = 'LT'.
 
 
 
 
 
 
 
 
 
 
 
DATA(ld_i_dialog) = 'X'.
 
 
DATA(ld_i_user_specific) = ' '.
 
DATA(ld_i_default) = 'X'.
 
 
 
 


Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!