SAP CNLS_INITIALIZATION Function Module for NOTRANSL: Projekt-Infosystem: Initialisierung der Daten
CNLS_INITIALIZATION is a standard cnls initialization 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: Projekt-Infosystem: Initialisierung der Daten 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 cnls initialization FM, simply by entering the name CNLS_INITIALIZATION into the relevant SAP transaction such as SE37 or SE38.
Function Group: CNLS
Program Name: SAPLCNLS
Main Program:
Appliation area: C
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function CNLS_INITIALIZATION 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 'CNLS_INITIALIZATION'"NOTRANSL: Projekt-Infosystem: Initialisierung der Daten.
EXPORTING
I_MCINF_TAB = "Table Name
* I_OBJNR_FELD = "Field Name
* I_LOEKZ_FELD = "Field Name
* I_ALT_SCRTEXT_TABNAME = "Table Name
* I_TITELTEXT_GLOBAL = "DE-EN-LANG-SWITCH-NO-TRANSLATION
* I_TITELTEXT_SPEZIAL = "DE-EN-LANG-SWITCH-NO-TRANSLATION
* I_EXIT_PROGNAME = "Predefined Type
* I_TEXTPOOL = 'SAPLCNIS' "Predefined Type
* I_KURZTEXT_FELD = "Field Name
* I_ARBID_FELD = "Field Name
* I_KALID_FELD = "Field Name
* I_STATXT_FELD = "Field Name
CHANGING
* SUM_REST = "DE-EN-LANG-SWITCH-NO-TRANSLATION
MAX_FIELDS = "
SUM_FIELDS = "
UNITS = "
SUM_UNITS = "
TABLES
AUS_S000 = "DE-EN-LANG-SWITCH-NO-TRANSLATION
INT_S000 = "DE-EN-LANG-SWITCH-NO-TRANSLATION
* SUM_S000 = "DE-EN-LANG-SWITCH-NO-TRANSLATION
* PUFFERTAB = "DE-EN-LANG-SWITCH-NO-TRANSLATION
* XXL_DATA = "DE-EN-LANG-SWITCH-NO-TRANSLATION
IMPORTING Parameters details for CNLS_INITIALIZATION
I_MCINF_TAB - Table Name
Data type: DFIES-TABNAMEOptional: No
Call by Reference: No ( called with pass by value option)
I_OBJNR_FELD - Field Name
Data type: DFIES-FIELDNAMEOptional: Yes
Call by Reference: No ( called with pass by value option)
I_LOEKZ_FELD - Field Name
Data type: DFIES-FIELDNAMEOptional: Yes
Call by Reference: No ( called with pass by value option)
I_ALT_SCRTEXT_TABNAME - Table Name
Data type: DFIES-TABNAMEOptional: Yes
Call by Reference: No ( called with pass by value option)
I_TITELTEXT_GLOBAL - DE-EN-LANG-SWITCH-NO-TRANSLATION
Data type:Optional: Yes
Call by Reference: No ( called with pass by value option)
I_TITELTEXT_SPEZIAL - DE-EN-LANG-SWITCH-NO-TRANSLATION
Data type:Optional: Yes
Call by Reference: No ( called with pass by value option)
I_EXIT_PROGNAME - Predefined Type
Data type: SY-REPIDOptional: Yes
Call by Reference: No ( called with pass by value option)
I_TEXTPOOL - Predefined Type
Data type: SY-REPIDDefault: 'SAPLCNIS'
Optional: Yes
Call by Reference: No ( called with pass by value option)
I_KURZTEXT_FELD - Field Name
Data type: DFIES-FIELDNAMEOptional: Yes
Call by Reference: No ( called with pass by value option)
I_ARBID_FELD - Field Name
Data type: DFIES-FIELDNAMEOptional: Yes
Call by Reference: No ( called with pass by value option)
I_KALID_FELD - Field Name
Data type: DFIES-FIELDNAMEOptional: Yes
Call by Reference: No ( called with pass by value option)
I_STATXT_FELD - Field Name
Data type: DFIES-FIELDNAMEOptional: Yes
Call by Reference: No ( called with pass by value option)
CHANGING Parameters details for CNLS_INITIALIZATION
SUM_REST - DE-EN-LANG-SWITCH-NO-TRANSLATION
Data type:Optional: Yes
Call by Reference: Yes
MAX_FIELDS -
Data type:Optional: No
Call by Reference: Yes
SUM_FIELDS -
Data type:Optional: No
Call by Reference: Yes
UNITS -
Data type:Optional: No
Call by Reference: Yes
SUM_UNITS -
Data type:Optional: No
Call by Reference: Yes
TABLES Parameters details for CNLS_INITIALIZATION
AUS_S000 - DE-EN-LANG-SWITCH-NO-TRANSLATION
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
INT_S000 - DE-EN-LANG-SWITCH-NO-TRANSLATION
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
SUM_S000 - DE-EN-LANG-SWITCH-NO-TRANSLATION
Data type:Optional: Yes
Call by Reference: No ( called with pass by value option)
PUFFERTAB - DE-EN-LANG-SWITCH-NO-TRANSLATION
Data type:Optional: Yes
Call by Reference: No ( called with pass by value option)
XXL_DATA - DE-EN-LANG-SWITCH-NO-TRANSLATION
Data type:Optional: Yes
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for CNLS_INITIALIZATION 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_aus_s000 | TYPE STANDARD TABLE OF STRING, " | |||
| lv_sum_rest | TYPE STRING, " | |||
| lv_i_mcinf_tab | TYPE DFIES-TABNAME, " | |||
| lv_i_objnr_feld | TYPE DFIES-FIELDNAME, " | |||
| lv_i_loekz_feld | TYPE DFIES-FIELDNAME, " | |||
| lv_i_alt_scrtext_tabname | TYPE DFIES-TABNAME, " | |||
| lt_int_s000 | TYPE STANDARD TABLE OF DFIES, " | |||
| lv_max_fields | TYPE DFIES, " | |||
| lv_i_titeltext_global | TYPE DFIES, " | |||
| lt_sum_s000 | TYPE STANDARD TABLE OF DFIES, " | |||
| lv_sum_fields | TYPE DFIES, " | |||
| lv_i_titeltext_spezial | TYPE DFIES, " | |||
| lv_units | TYPE DFIES, " | |||
| lt_puffertab | TYPE STANDARD TABLE OF DFIES, " | |||
| lv_i_exit_progname | TYPE SY-REPID, " | |||
| lt_xxl_data | TYPE STANDARD TABLE OF SY, " | |||
| lv_sum_units | TYPE SY, " | |||
| lv_i_textpool | TYPE SY-REPID, " 'SAPLCNIS' | |||
| lv_i_kurztext_feld | TYPE DFIES-FIELDNAME, " | |||
| lv_i_arbid_feld | TYPE DFIES-FIELDNAME, " | |||
| lv_i_kalid_feld | TYPE DFIES-FIELDNAME, " | |||
| lv_i_statxt_feld | TYPE DFIES-FIELDNAME. " |
|   CALL FUNCTION 'CNLS_INITIALIZATION' "NOTRANSL: Projekt-Infosystem: Initialisierung der Daten |
| EXPORTING | ||
| I_MCINF_TAB | = lv_i_mcinf_tab | |
| I_OBJNR_FELD | = lv_i_objnr_feld | |
| I_LOEKZ_FELD | = lv_i_loekz_feld | |
| I_ALT_SCRTEXT_TABNAME | = lv_i_alt_scrtext_tabname | |
| I_TITELTEXT_GLOBAL | = lv_i_titeltext_global | |
| I_TITELTEXT_SPEZIAL | = lv_i_titeltext_spezial | |
| I_EXIT_PROGNAME | = lv_i_exit_progname | |
| I_TEXTPOOL | = lv_i_textpool | |
| I_KURZTEXT_FELD | = lv_i_kurztext_feld | |
| I_ARBID_FELD | = lv_i_arbid_feld | |
| I_KALID_FELD | = lv_i_kalid_feld | |
| I_STATXT_FELD | = lv_i_statxt_feld | |
| CHANGING | ||
| SUM_REST | = lv_sum_rest | |
| MAX_FIELDS | = lv_max_fields | |
| SUM_FIELDS | = lv_sum_fields | |
| UNITS | = lv_units | |
| SUM_UNITS | = lv_sum_units | |
| TABLES | ||
| AUS_S000 | = lt_aus_s000 | |
| INT_S000 | = lt_int_s000 | |
| SUM_S000 | = lt_sum_s000 | |
| PUFFERTAB | = lt_puffertab | |
| XXL_DATA | = lt_xxl_data | |
| . " CNLS_INITIALIZATION | ||
ABAP code using 7.40 inline data declarations to call FM CNLS_INITIALIZATION
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 TABNAME FROM DFIES INTO @DATA(ld_i_mcinf_tab). | ||||
| "SELECT single FIELDNAME FROM DFIES INTO @DATA(ld_i_objnr_feld). | ||||
| "SELECT single FIELDNAME FROM DFIES INTO @DATA(ld_i_loekz_feld). | ||||
| "SELECT single TABNAME FROM DFIES INTO @DATA(ld_i_alt_scrtext_tabname). | ||||
| "SELECT single REPID FROM SY INTO @DATA(ld_i_exit_progname). | ||||
| "SELECT single REPID FROM SY INTO @DATA(ld_i_textpool). | ||||
| DATA(ld_i_textpool) | = 'SAPLCNIS'. | |||
| "SELECT single FIELDNAME FROM DFIES INTO @DATA(ld_i_kurztext_feld). | ||||
| "SELECT single FIELDNAME FROM DFIES INTO @DATA(ld_i_arbid_feld). | ||||
| "SELECT single FIELDNAME FROM DFIES INTO @DATA(ld_i_kalid_feld). | ||||
| "SELECT single FIELDNAME FROM DFIES INTO @DATA(ld_i_statxt_feld). | ||||
Search for further information about these or an SAP related objects