SAP MS_READ_LIMITS Function Module for NOTRANSL: Lesen Limits
MS_READ_LIMITS is a standard ms read limits SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for NOTRANSL: Lesen Limits processing and below is the pattern details for this FM, 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 ms read limits FM, simply by entering the name MS_READ_LIMITS into the relevant SAP transaction such as SE37 or SE38.
Function Group: MLSL
Program Name: SAPLMLSL
Main Program: SAPLMLSL
Appliation area: M
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function MS_READ_LIMITS 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 'MS_READ_LIMITS'"NOTRANSL: Lesen Limits.
EXPORTING
PACKNO = "
* I_ORIGIN = ' ' "
* I_COMSRV = ' ' "
* I_CURSOR_FIELD = "Name of a Screen Element
* I_LIMIT_LINE = "Screens: Index of Current Table Line
IMPORTING
E_ESUH = "
TABLES
LIMIT_TAB = "
EXCEPTIONS
NO_LIMITS_FOUND = 1
Customer Function user exits
Below is a list of CUSTOMER FUNCTION exit user exits that are available within this program and maybe relevant for this FM.EXIT_SAPLMLSL_001 Check Limits in Service Specifications
IMPORTING Parameters details for MS_READ_LIMITS
PACKNO -
Data type: ESLH-PACKNOOptional: No
Call by Reference: No ( called with pass by value option)
I_ORIGIN -
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
I_COMSRV -
Data type: COMSRVDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
I_CURSOR_FIELD - Name of a Screen Element
Data type: SCRFNAMEOptional: Yes
Call by Reference: No ( called with pass by value option)
I_LIMIT_LINE - Screens: Index of Current Table Line
Data type: SY-STEPLOptional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for MS_READ_LIMITS
E_ESUH -
Data type: ESUHOptional: No
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for MS_READ_LIMITS
LIMIT_TAB -
Data type: ESUCOptional: No
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
NO_LIMITS_FOUND -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for MS_READ_LIMITS 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_esuh | TYPE ESUH, " | |||
| lv_packno | TYPE ESLH-PACKNO, " | |||
| lt_limit_tab | TYPE STANDARD TABLE OF ESUC, " | |||
| lv_no_limits_found | TYPE ESUC, " | |||
| lv_i_origin | TYPE ESUC, " SPACE | |||
| lv_i_comsrv | TYPE COMSRV, " SPACE | |||
| lv_i_cursor_field | TYPE SCRFNAME, " | |||
| lv_i_limit_line | TYPE SY-STEPL. " |
|   CALL FUNCTION 'MS_READ_LIMITS' "NOTRANSL: Lesen Limits |
| EXPORTING | ||
| PACKNO | = lv_packno | |
| I_ORIGIN | = lv_i_origin | |
| I_COMSRV | = lv_i_comsrv | |
| I_CURSOR_FIELD | = lv_i_cursor_field | |
| I_LIMIT_LINE | = lv_i_limit_line | |
| IMPORTING | ||
| E_ESUH | = lv_e_esuh | |
| TABLES | ||
| LIMIT_TAB | = lt_limit_tab | |
| EXCEPTIONS | ||
| NO_LIMITS_FOUND = 1 | ||
| . " MS_READ_LIMITS | ||
ABAP code using 7.40 inline data declarations to call FM MS_READ_LIMITS
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 PACKNO FROM ESLH INTO @DATA(ld_packno). | ||||
| DATA(ld_i_origin) | = ' '. | |||
| DATA(ld_i_comsrv) | = ' '. | |||
| "SELECT single STEPL FROM SY INTO @DATA(ld_i_limit_line). | ||||
Search for further information about these or an SAP related objects