Entering content frameProcedure documentation Retrieving Data for Customer Fields Locate the document in its SAP Library structure

Prerequisites

You have extended the communication structure MCWF_TRANS with your own append structure.

Procedure

  1. Go to the area menu of the WIS and choose Environment ® Enhancements ® Selection program.
  2. The function module EXIT_SAPLMCWF_001 is set as a default.

    When called, the function module receives the internal table XMCWF_TRANS with the communication structure MCWF_TRANS as a table parameter. The fields defined by SAP are already filled.

  3. Program the source code for this function module.

Use the form routine WIS_CODING_TEMPLATE of the main program SAPLMCWF as a guide. (Transaction SE80, function group MCWF). The procedure is exactly the same.

First program an IF or CASE construction, to make sure that you analyze work items for particular tasks only. The task ID is in the field XMCWF_TRANS-WI_RH_TASK.

Use one of the two function modules SWI_READ_CONTAINER_ELEMENT or SWI_READ_CONTAINER_ATTRIBUTE within the IF or CASE construction so that each of your self-defined fields can read the appropriate data from the runtime tables.

Both function modules are called with the following parameters:

The work item ID is recognized from the field MCWF_TRANS-WI_ID.

ID of the container element.

The function module SWI_READ_CONTAINER_ATTRIBUTE also has the import parameter ATTRIBUTE (attribute of an object that is referenced in ELEMENT).

Both function modules return the value in the element VALUE.

Use this to fill the communication structure MCWF_TRANS.

  1. Activate the user exit EXIT_SAPLMCWF_001.
  2. Use transaction SMOD/CMOD to activate the project or the SAP enhancement WISEXIT.

 

 

 

 

 

Leaving content frame