cancel
Showing results for 
Search instead for 
Did you mean: 

Dynamic Action-A Subty field to populate dynamically from employee position

0 Kudos

Hellooo People,

I'm a bit confused in creating a Dynamic action for one our sepc.

Here the Clients req is...there is custom IT say 'ABCD' wirh a Subtype '1234', which has a field "ID"....Ideally if it is possible we would like this to populate dynamically from the employee position.

Ex: of the fields which needs to get default in the subtype is below

ID Name

22 name of the ID

xx xxxxxx

xx xxxxxx

xx xxxxxx

0001 04 02 T001P-MOLGA='30'

0001 04 04 P0000-WERKS='LU90'

0001 04 06 P0000-PERSK='L1'

0001 04 08 INS,ABCD,1234

0001 04 10 P9002-ID='22'

Please suggest me on this.

Thanks

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Gracy Singh,

please read this

A dynamic action has the following components.

Infotype Number (INFTY): specifies the infotype for which you want the dynamic action triggered

Subtype (SUBTY): narrows the focus to a specific subtype

Field Name (FIELDN): starts your action when a maintenance function is performed on a particular field

Function (FC): specifies the various maintenance operations to which your dynamic action would respond. They are 02 (change); 04 (create); 06 (create and change); 08 (delete); 10 (change and delete); 12 (create and delete). Dynamic actions are only applicable in maintenance operations, not in display functions.

Sequence Number (NO): refers to a sequential number.

Step (A): specifies a particular type of action. No dynamic action is executed if the function character has a value other than one of the following:

P: Plausibility checks, which allow you to check certain conditions.

I: Calls an infotype for processing

W: Called after the I statement and used to assign values to screen fields while creating or copying another infotype record through the I statement

F: Calls a FORM routine (subroutines in ABAP) during your action. The routine may reside in or out the module pool MPNNNN00.

V: Lets you treat collectively a number of fields for which you want to define a common dynamic action

M: Sends SAP Office mail

Variable function part: The variable function part along with the step indicator forms the core part of your action. It specifies the processing details when the dynamic action is triggered. For example:

Now what is your business requirement.

for one business scenarion plz find the personnel action

Requirement: When the postal code or the city of an employeeu2019s permanent residence is changed in infotype 0006, an email should be sent to the administrator.

INFTY SUBTY FIELDN FC NO. STEP VARIABLE FUNCTION

0006 1 ORT01 06 001 V PSTLZ

0006 1 PSTLZ 06 002 M M0001

The V statement on line 001 is used to link the two fields to the M statement. The statements relevant to field PSTLZ are also applicable to the ORT01 field.

When a record is created or changed in infotype 0006 of permanent address, an email is sent using the feature M0001. Information such as the recipient address, subject, and content of the mail is derived from M0001.

now you have to write your requirement in the business requirement clearly.

hoping that you will write your dynamic action.

Warm Regards,

Kapil Kaushal

0 Kudos

Hi

Here is the requirement

INFTY SUBTY FIELDN FC NO. STEP VARIABLE FUNCTION

0001 04 02 T001P-MOLGA='30'

0001 04 04 P0001-WERKS='LU90'

0001 04 06 P0001-PERSK='L1'

0001 04 08 INS,ABCD,1234

0001 04 10 P9002-ID='22'

As you can see in the above Dynamic action which I wrote is not working

By checking the country grouping, WERKS, PERSK in IT0001 when every I try to maintain a record in the custom ITABCD and its corresponding Subtype1234, wich has a field ID which needs get populated dynamically (say 22).

Please correct me if Im wrong.

Thanks

0 Kudos

Sorry Forgot to put step

INFTY SUBTY FIELDN FC NO. STEP VARIABLE FUNCTION

0001 04 02 P T001P-MOLGA='30'

0001 04 04 P P0001-WERKS='LU90'

0001 04 06 P P0001-PERSK='L1'

0001 04 08 I INS,ABCD,1234

0001 04 10 W P9002-ID='22'