SAP MCS_CSTRUCTURE_USAGE Function Module for NOTRANSL: Verwendungungsnachweis für Kommunikationsstrukturen in Ereigniss
MCS_CSTRUCTURE_USAGE is a standard mcs cstructure usage 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: Verwendungungsnachweis für Kommunikationsstrukturen in Ereigniss 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 mcs cstructure usage FM, simply by entering the name MCS_CSTRUCTURE_USAGE into the relevant SAP transaction such as SE37 or SE38.
Function Group: MCSE
Program Name: SAPLMCSE
Main Program: SAPLMCSE
Appliation area: M
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function MCS_CSTRUCTURE_USAGE 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 'MCS_CSTRUCTURE_USAGE'"NOTRANSL: Verwendungungsnachweis für Kommunikationsstrukturen in Ereigniss.
EXPORTING
I_CSTRU = "Communication structure
* CHECK_ONLY = ' ' "Check if Cstru only exists once
IMPORTING
E_ZEITP = "Event, when check_only active
E_ENTRY_FBS = "
E_IDCO_FBS = "
TABLES
* T_TMC20 = "Events when check_only deactivated
EXCEPTIONS
NO_EVENT_TO_CSTRUCTURE = 1 SEVERAL_EVENTS_AVAILABLE = 2
IMPORTING Parameters details for MCS_CSTRUCTURE_USAGE
I_CSTRU - Communication structure
Data type: DMCSE-CSTRUOptional: No
Call by Reference: No ( called with pass by value option)
CHECK_ONLY - Check if Cstru only exists once
Data type: XFLAGDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for MCS_CSTRUCTURE_USAGE
E_ZEITP - Event, when check_only active
Data type: DMCSE-ZEITPOptional: No
Call by Reference: No ( called with pass by value option)
E_ENTRY_FBS -
Data type: TMC5-FBSNAMEOptional: No
Call by Reference: No ( called with pass by value option)
E_IDCO_FBS -
Data type: TMC5-FBSNAMEOptional: No
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for MCS_CSTRUCTURE_USAGE
T_TMC20 - Events when check_only deactivated
Data type: TMC20Optional: Yes
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
NO_EVENT_TO_CSTRUCTURE -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
SEVERAL_EVENTS_AVAILABLE - Several events when check_only active
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for MCS_CSTRUCTURE_USAGE 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_zeitp | TYPE DMCSE-ZEITP, " | |||
| lv_i_cstru | TYPE DMCSE-CSTRU, " | |||
| lt_t_tmc20 | TYPE STANDARD TABLE OF TMC20, " | |||
| lv_no_event_to_cstructure | TYPE TMC20, " | |||
| lv_check_only | TYPE XFLAG, " SPACE | |||
| lv_e_entry_fbs | TYPE TMC5-FBSNAME, " | |||
| lv_several_events_available | TYPE TMC5, " | |||
| lv_e_idco_fbs | TYPE TMC5-FBSNAME. " |
|   CALL FUNCTION 'MCS_CSTRUCTURE_USAGE' "NOTRANSL: Verwendungungsnachweis für Kommunikationsstrukturen in Ereigniss |
| EXPORTING | ||
| I_CSTRU | = lv_i_cstru | |
| CHECK_ONLY | = lv_check_only | |
| IMPORTING | ||
| E_ZEITP | = lv_e_zeitp | |
| E_ENTRY_FBS | = lv_e_entry_fbs | |
| E_IDCO_FBS | = lv_e_idco_fbs | |
| TABLES | ||
| T_TMC20 | = lt_t_tmc20 | |
| EXCEPTIONS | ||
| NO_EVENT_TO_CSTRUCTURE = 1 | ||
| SEVERAL_EVENTS_AVAILABLE = 2 | ||
| . " MCS_CSTRUCTURE_USAGE | ||
ABAP code using 7.40 inline data declarations to call FM MCS_CSTRUCTURE_USAGE
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 ZEITP FROM DMCSE INTO @DATA(ld_e_zeitp). | ||||
| "SELECT single CSTRU FROM DMCSE INTO @DATA(ld_i_cstru). | ||||
| DATA(ld_check_only) | = ' '. | |||
| "SELECT single FBSNAME FROM TMC5 INTO @DATA(ld_e_entry_fbs). | ||||
| "SELECT single FBSNAME FROM TMC5 INTO @DATA(ld_e_idco_fbs). | ||||
Search for further information about these or an SAP related objects