SAP RULE_MTE_TREE_GET Function Module for









RULE_MTE_TREE_GET is a standard rule mte tree get 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 rule mte tree get FM, simply by entering the name RULE_MTE_TREE_GET into the relevant SAP transaction such as SE37 or SE38.

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



Function RULE_MTE_TREE_GET 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 'RULE_MTE_TREE_GET'"
EXPORTING
VISUAL_USER_LEVEL = "
* USED_IN_DIALOG = 'X' "

TABLES
IN_TIDS_LNAMES = "
OUT_MT_TREES = "

EXCEPTIONS
TIDS_LNAMES_INFO_MISSING = 1 CANT_HANDLE_VIRTUAL_TID = 2 CANT_CREATE_ERRONOUS_MT_NODE = 3 CANT_DETERMINE_MT_TYPE = 4 CANT_GET_MT_TREE = 5 INVALID_VISUAL_USER_LEVEL = 6
.



IMPORTING Parameters details for RULE_MTE_TREE_GET

VISUAL_USER_LEVEL -

Data type: ALVISLVLRB
Optional: No
Call by Reference: Yes

USED_IN_DIALOG -

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

TABLES Parameters details for RULE_MTE_TREE_GET

IN_TIDS_LNAMES -

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

OUT_MT_TREES -

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

EXCEPTIONS details

TIDS_LNAMES_INFO_MISSING -

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

CANT_HANDLE_VIRTUAL_TID -

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

CANT_CREATE_ERRONOUS_MT_NODE -

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

CANT_DETERMINE_MT_TYPE -

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

CANT_GET_MT_TREE -

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

INVALID_VISUAL_USER_LEVEL -

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

Copy and paste ABAP code example for RULE_MTE_TREE_GET 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:
lt_in_tids_lnames  TYPE STANDARD TABLE OF CCMSM_TID_LNAME_INFO_TBL, "   
lv_visual_user_level  TYPE ALVISLVLRB, "   
lv_tids_lnames_info_missing  TYPE ALVISLVLRB, "   
lt_out_mt_trees  TYPE STANDARD TABLE OF CCMSM_MT_TREE_TBL, "   
lv_used_in_dialog  TYPE ALTYPES-CHAR1, "   'X'
lv_cant_handle_virtual_tid  TYPE ALTYPES, "   
lv_cant_create_erronous_mt_node  TYPE ALTYPES, "   
lv_cant_determine_mt_type  TYPE ALTYPES, "   
lv_cant_get_mt_tree  TYPE ALTYPES, "   
lv_invalid_visual_user_level  TYPE ALTYPES. "   

  CALL FUNCTION 'RULE_MTE_TREE_GET'  "
    EXPORTING
         VISUAL_USER_LEVEL = lv_visual_user_level
         USED_IN_DIALOG = lv_used_in_dialog
    TABLES
         IN_TIDS_LNAMES = lt_in_tids_lnames
         OUT_MT_TREES = lt_out_mt_trees
    EXCEPTIONS
        TIDS_LNAMES_INFO_MISSING = 1
        CANT_HANDLE_VIRTUAL_TID = 2
        CANT_CREATE_ERRONOUS_MT_NODE = 3
        CANT_DETERMINE_MT_TYPE = 4
        CANT_GET_MT_TREE = 5
        INVALID_VISUAL_USER_LEVEL = 6
. " RULE_MTE_TREE_GET




ABAP code using 7.40 inline data declarations to call FM RULE_MTE_TREE_GET

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 CHAR1 FROM ALTYPES INTO @DATA(ld_used_in_dialog).
DATA(ld_used_in_dialog) = '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!