SAP SXMI_LOGMSG_ENTER Function Module for Enter External Message in XMI Log
SXMI_LOGMSG_ENTER is a standard sxmi logmsg enter SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Enter External Message in XMI Log 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 sxmi logmsg enter FM, simply by entering the name SXMI_LOGMSG_ENTER into the relevant SAP transaction such as SE37 or SE38.
Function Group: SXMI
Program Name: SAPLSXMI
Main Program: SAPLSXMI
Appliation area: S
Release date: 14-Jan-1997
Mode(Normal, Remote etc): Remote-Enabled
Update:

Function SXMI_LOGMSG_ENTER 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 'SXMI_LOGMSG_ENTER'"Enter External Message in XMI Log.
EXPORTING
* EXTUSER = "Tool user affected by the message
* MSGARG3 = "3rd message argument
* ARGTYPE3 = 'C' "Type of 3rd message argument
* MSGARG4 = "4th message argument
* ARGTYPE4 = 'C' "Type of 4th message argument
* INTERFACE = "Interface affected by the message
* OBJECT = "Object affected by the message
* MSGID = "Message ID in manufacturer namespace
MSGTEXT = "Standard message or text message
* MSGARG1 = "1st message argument
* ARGTYPE1 = 'C' "Type of 1st message argument
* MSGARG2 = "2nd message argument
* ARGTYPE2 = 'C' "Type of 2nd message argument
EXCEPTIONS
NOT_LOGGED_ON = 1 INVALID_PARAMETERS = 2 CANT_LOG = 3 PROBLEM_DETECTED = 4
IMPORTING Parameters details for SXMI_LOGMSG_ENTER
EXTUSER - Tool user affected by the message
Data type: TXMILOGRAW-EXTUSEROptional: Yes
Call by Reference: No ( called with pass by value option)
MSGARG3 - 3rd message argument
Data type: TXMILOGRAW-MSGARG3Optional: Yes
Call by Reference: No ( called with pass by value option)
ARGTYPE3 - Type of 3rd message argument
Data type: TXMILOGRAW-ARGTYPE3Default: 'C'
Optional: Yes
Call by Reference: No ( called with pass by value option)
MSGARG4 - 4th message argument
Data type: TXMILOGRAW-MSGARG4Optional: Yes
Call by Reference: No ( called with pass by value option)
ARGTYPE4 - Type of 4th message argument
Data type: TXMILOGRAW-ARGTYPE4Default: 'C'
Optional: Yes
Call by Reference: No ( called with pass by value option)
INTERFACE - Interface affected by the message
Data type: TXMILOGRAW-INTERFACEOptional: Yes
Call by Reference: No ( called with pass by value option)
OBJECT - Object affected by the message
Data type: TXMILOGRAW-OBJECTOptional: Yes
Call by Reference: No ( called with pass by value option)
MSGID - Message ID in manufacturer namespace
Data type: TXMILOGRAW-MSGIDOptional: Yes
Call by Reference: No ( called with pass by value option)
MSGTEXT - Standard message or text message
Data type: TXMILOGRAW-MSGTEXTOptional: No
Call by Reference: No ( called with pass by value option)
MSGARG1 - 1st message argument
Data type: TXMILOGRAW-MSGARG1Optional: Yes
Call by Reference: No ( called with pass by value option)
ARGTYPE1 - Type of 1st message argument
Data type: TXMILOGRAW-ARGTYPE1Default: 'C'
Optional: Yes
Call by Reference: No ( called with pass by value option)
MSGARG2 - 2nd message argument
Data type: TXMILOGRAW-MSGARG2Optional: Yes
Call by Reference: No ( called with pass by value option)
ARGTYPE2 - Type of 2nd message argument
Data type: TXMILOGRAW-ARGTYPE2Default: 'C'
Optional: Yes
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
NOT_LOGGED_ON - Tool not logged on in XMI framework
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
INVALID_PARAMETERS - Arguments have invalid values
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
CANT_LOG - Message could not be stored in the log
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
PROBLEM_DETECTED - Internal problem (see system log)
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for SXMI_LOGMSG_ENTER 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_extuser | TYPE TXMILOGRAW-EXTUSER, " | |||
| lv_not_logged_on | TYPE TXMILOGRAW, " | |||
| lv_msgarg3 | TYPE TXMILOGRAW-MSGARG3, " | |||
| lv_argtype3 | TYPE TXMILOGRAW-ARGTYPE3, " 'C' | |||
| lv_msgarg4 | TYPE TXMILOGRAW-MSGARG4, " | |||
| lv_argtype4 | TYPE TXMILOGRAW-ARGTYPE4, " 'C' | |||
| lv_interface | TYPE TXMILOGRAW-INTERFACE, " | |||
| lv_invalid_parameters | TYPE TXMILOGRAW, " | |||
| lv_object | TYPE TXMILOGRAW-OBJECT, " | |||
| lv_cant_log | TYPE TXMILOGRAW, " | |||
| lv_msgid | TYPE TXMILOGRAW-MSGID, " | |||
| lv_problem_detected | TYPE TXMILOGRAW, " | |||
| lv_msgtext | TYPE TXMILOGRAW-MSGTEXT, " | |||
| lv_msgarg1 | TYPE TXMILOGRAW-MSGARG1, " | |||
| lv_argtype1 | TYPE TXMILOGRAW-ARGTYPE1, " 'C' | |||
| lv_msgarg2 | TYPE TXMILOGRAW-MSGARG2, " | |||
| lv_argtype2 | TYPE TXMILOGRAW-ARGTYPE2. " 'C' |
|   CALL FUNCTION 'SXMI_LOGMSG_ENTER' "Enter External Message in XMI Log |
| EXPORTING | ||
| EXTUSER | = lv_extuser | |
| MSGARG3 | = lv_msgarg3 | |
| ARGTYPE3 | = lv_argtype3 | |
| MSGARG4 | = lv_msgarg4 | |
| ARGTYPE4 | = lv_argtype4 | |
| INTERFACE | = lv_interface | |
| OBJECT | = lv_object | |
| MSGID | = lv_msgid | |
| MSGTEXT | = lv_msgtext | |
| MSGARG1 | = lv_msgarg1 | |
| ARGTYPE1 | = lv_argtype1 | |
| MSGARG2 | = lv_msgarg2 | |
| ARGTYPE2 | = lv_argtype2 | |
| EXCEPTIONS | ||
| NOT_LOGGED_ON = 1 | ||
| INVALID_PARAMETERS = 2 | ||
| CANT_LOG = 3 | ||
| PROBLEM_DETECTED = 4 | ||
| . " SXMI_LOGMSG_ENTER | ||
ABAP code using 7.40 inline data declarations to call FM SXMI_LOGMSG_ENTER
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 EXTUSER FROM TXMILOGRAW INTO @DATA(ld_extuser). | ||||
| "SELECT single MSGARG3 FROM TXMILOGRAW INTO @DATA(ld_msgarg3). | ||||
| "SELECT single ARGTYPE3 FROM TXMILOGRAW INTO @DATA(ld_argtype3). | ||||
| DATA(ld_argtype3) | = 'C'. | |||
| "SELECT single MSGARG4 FROM TXMILOGRAW INTO @DATA(ld_msgarg4). | ||||
| "SELECT single ARGTYPE4 FROM TXMILOGRAW INTO @DATA(ld_argtype4). | ||||
| DATA(ld_argtype4) | = 'C'. | |||
| "SELECT single INTERFACE FROM TXMILOGRAW INTO @DATA(ld_interface). | ||||
| "SELECT single OBJECT FROM TXMILOGRAW INTO @DATA(ld_object). | ||||
| "SELECT single MSGID FROM TXMILOGRAW INTO @DATA(ld_msgid). | ||||
| "SELECT single MSGTEXT FROM TXMILOGRAW INTO @DATA(ld_msgtext). | ||||
| "SELECT single MSGARG1 FROM TXMILOGRAW INTO @DATA(ld_msgarg1). | ||||
| "SELECT single ARGTYPE1 FROM TXMILOGRAW INTO @DATA(ld_argtype1). | ||||
| DATA(ld_argtype1) | = 'C'. | |||
| "SELECT single MSGARG2 FROM TXMILOGRAW INTO @DATA(ld_msgarg2). | ||||
| "SELECT single ARGTYPE2 FROM TXMILOGRAW INTO @DATA(ld_argtype2). | ||||
| DATA(ld_argtype2) | = 'C'. | |||
Search for further information about these or an SAP related objects