Skip to Content

This document is part 3 of what builds on my other example:  “Part 2: basic HCM Process and Forms scenario (Address Type 0006, Subtype 4 is included)” which can be accessed at: http://scn.sap.com/docs/DOC-35583

Let’s make the Form Process even more functional by allowing the change of address while still being able to view the currently stored address.  We are still using Subtype 4 from InfoType 0006 for this example.

Click on Fields (within our Scenario) and add the following fields:

/wp-content/uploads/2013/01/pic__179722.jpg

Field Name: LAND1_STATIC

Name: Country

DataBinding: LAND1

Field Name: STRAS_STATIC

Name: Address Line 1

DataBinding: PAD_STRAS

Field Name: LOCAT_STATIC

Name: Address Line 2

DataBinding: PAD_LOCAT

Field Name: NAME2_STATIC

Name: Contact Name

DataBinding: PAD_CONAM

Field Name: ORT01_STATIC

Name: City

DataBinding: PAD_ORT01

Field Name: STATE_STATIC

Name: State

DataBinding: REGIO

Field Name: PSTLZ_STATIC

Name: Zip

DataBinding: PSTLZ_HR

Field Name: ORT02_STATIC

Name: County

DataBinding: PAD_ORT02

Result of adding all fields:

/wp-content/uploads/2013/01/pic1_179744.jpg

We now need to add these fields to our Back-End Service SAP_PA.  Double Click on Back-End Services -> SAP_PA -> Fields:

/wp-content/uploads/2013/01/pic__179722.jpg

Add the following Field information and hit enter:

Field Name: LAND1_STATIC

Name: Country

InfoType: 0006

Subtype: 4

ScreenStruct: HCMT_BSP_PA_US_R0006

Field Name: LAND1

Field Name: STRAS_STATIC

Name: Address Line 1

InfoType: 0006

Subtype: 4

ScreenStruct: HCMT_BSP_PA_US_R0006

Field Name: STRAS

Field Name: LOCAT_STATIC

Name: Address Line 2

InfoType: 0006

Subtype: 4

ScreenStruct: HCMT_BSP_PA_US_R0006

Field Name: LOCAT

Field Name: NAME2_STATIC

Name: Contact Name

InfoType: 0006

Subtype: 4

ScreenStruct: HCMT_BSP_PA_US_R0006

Field Name: NAME2

Field Name: ORT01_STATIC

Name: City

InfoType: 0006

Subtype: 4

ScreenStruct: HCMT_BSP_PA_US_R0006

Field Name: ORT01

Field Name: STATE_STATIC

Name: State

InfoType: 0006

Subtype: 4

ScreenStruct: HCMT_BSP_PA_US_R0006

Field Name: STATE

Field Name: PSTLZ_STATIC

Name: Zip

InfoType: 0006

Subtype: 4

ScreenStruct: HCMT_BSP_PA_US_R0006

Field Name: PSTLZ

Field Name: ORT02_STATIC

Name: County

InfoType: 0006

Subtype: 4

ScreenStruct: HCMT_BSP_PA_US_R0006

Field Name: ORT02

Result of all Fields added:

/wp-content/uploads/2013/01/pic__179722.jpg

We want to default in the employee’s current address (subtype 4) if they have one on record.  To do this, double click the column “Default” on each of the field’s row and select “CUR”.  Result:

/wp-content/uploads/2013/01/pic1_179744.jpg

Save your changes.  You will notice, that the operation for these new fields indicates that we are going to perform a “Change”.  This is because our “Infotypes
and Operations” specifies change:

/wp-content/uploads/2013/01/pic__179722.jpg

Since we only want to display data in these new fields, we need to tell configuration to exclude these fields from any operation.  There is a column called: “Op. Exclusion”.  If we set the value in this column to “checked”, the corresponding fields are excluded from being operated on.  Check the box in this column for the newly added fields.  Results below:

/wp-content/uploads/2013/01/pic__179722.jpg

We have now completed all the needed steps in configuration to allow adding address fields for subtype 4 onto our form.  Double Click “Form” under your scenario:

/wp-content/uploads/2013/01/pic__179722.jpg

Choose “Change” (Pencil) to edit your form:

/wp-content/uploads/2013/01/pic__179722.jpg

This will launch the Adobe LifeCycle Designer.  The first thing we need to do is select the “Context” tab and see if our new fields are mapped from the Interface to the Form.  If not, drag them over:

/wp-content/uploads/2013/01/pic__179722.jpg

Now switch back to the layout tab so you are in the designer mode.  From the Object Library Palette, drag the “ISR Text Display” object onto your form.  We will need 8 of these.  The “ISR Text Display” object can be found in the ISR Native Controls section:

/wp-content/uploads/2013/01/pic__179722.jpg

Now from the Data View tab,we need to find the 8 new static fields we created from I.T. 0006 and add the data element by dragging them (BINDING) onto the “ISR Text Display” objects we just created.  Drag the lowest element “FIELD” from your fields and drop it onto your “ISR Text Display” objects.  To verify that binding is correct, you can always select your display object and look at the binding properties.  Remember to also update the texts for each field.  When complete, your form should look similar to:

/wp-content/uploads/2013/01/pic__179722.jpg

Save and activate your form.  Activate both the interface and form:

/wp-content/uploads/2013/01/pic__179722.jpg

Exit the form designer and return to your process configuration.

Now is a good time to test.  You can either logon to the portal and select your process or launch directly using:

http://yourserver.com/sap/bc/webdynpro/sap/asr_process_execute?sap-client=<yourclient #>&sap-language=EN

Results:  (Try saving and make sure your changes are saved to the backend SAP)

/wp-content/uploads/2013/01/pic__179722.jpg

To report this post you need to login first.

1 Comment

You must be Logged on to comment or reply to a post.

  1. Christopher Solomon

    This is one part of the HCM P&F framework I wish they could make easier. It is VERY common to have users that want to see “current” values while adding “new” ones. As of now, you end up with 2 sets of the same fields. Like…

    I0006_stras_old

    I0006_stras_new

    I have seen folks get “clever” with using index values (0 for old and 1 for new) so it only takes one form field but then that assumes whoever comes after will know/understand what the heck you did.

    There had got to be a better way! haha

    (0) 

Leave a Reply