Sie sind auf Seite 1von 10

Inserting data from Internal Table into the step "Send Mail"

By Sandeep Jape, Yash Technologies

Purpose: The purpose of this document is to insert multiple lines of an internal table in Send
Mail Step in workflow.
Business Scenario: This tutorial can be used wherever you need to insert multiple lines of an
internal table in Send Mail Step through workflow for example PR, PO rejection text.
Process: This demo creation will involve the following steps

Create custom workflow

Create container element

Fill Data in above created container element

Create Send Mail Step

Insert above container element in send mail step

Pre-requisites:

You should have the basic knowledge about workflow that how to create a workflow &
how to include Send Mail Step. (Please check other tutorials on SAPTechnical.COM for
your reference)

Workflow configurations using SWU3 is already done

Step 1: Go to transaction SWDD, create a custom workflow save the same as follows

Step 2: Create a container element by name DIS_TXT& keep the properties as follows

Note: We are not going to fill this DIS_TXT at run time instead we will create test data in Initial
Value section which will be used at the time of testing. Refer the below screen shot, append lines
using Append Row Button & press confirm button >>

Step 3: Create add step Send Mail which will look like the following >>
Note:

Keep the Recipient as &_WF_INITIATOR&

Add subject & mail text & press OK button & give the name to step as follows & save in a
request.

Now copy the task number of the send mail step & go to transaction PFTC >>

Inserting data from Internal Table into the step "Send Mail"
..Previous

Go to Transaction PFTC put your task & press change button >>

Now click on Container Tab & create an element as shown below >>

Note: Do not modify any standard mail step task, always copy & do the changes & use the same
in your custom WF.
Maintain properties for above element as shown below & save the task & exit >>

Step 4: Go back to workflow & send mail step >>

In mail step put your cursor on description & click o button Insert Expression

Double click on container element DIS_TXT & you will see following screen

Select last option All lines with line break. It will look like this
Note: For demo purpose I have included all 3 types

Press OK button & save the Workflow & activate


Step 5: Test the Workflow by pressing Test button as shown below

You will get following screen where press on execute button


Note: You can see the entries in container element DIS_TXT which we created earlier.

Now got to Transaction SBWP & click on Inbox & you will see our mail. Open it.

So we have successfully inserted multiple lines of an internal table in send mail step & displayed
in SBWP.
You can use this functionality in multitude of other ways as per your business requirement in your
project.
Creating the RFC Connection Names:

Go to TCODE SALE. Direct TCODE SM59


IMG Path IDoc Interface / Application Link Enabling (ALE) -> Communication -> Create RFC
Connections

Das könnte Ihnen auch gefallen