09-17-2008 11:09 AM
Hi
I have the foll. requirement.
In Infotype 8 when an employee enters the ANSAL field ie. the value for Annual Salary all the wage types should get populated on their own in the wage type table control in the screen based on the following calulations :
basic pay = 40% of ANSAL
HRA = 30% of basic. etc.
Please tell me where exactly I should write the code for this calculation and how.
09-18-2008 1:11 AM
You need to implement use exit EXIT_SAPFP50M_001, (cmod/smod thing)
and code something like this inside:
IF innnn-infty = '0008'.
call method cl_hr_pnnnn_type_cast=>prelp_to_pnnnn
exporting
prelp = innnn
importing
pnnnn = wa_p0008.
* Assign the values/calculations here
* wa_p0008-yourfield = whatever_you_want. "Change this line
* wa_p0008-yourfield = whatever_you_want. "Change this line
* etc.
* etc.
call method cl_hr_pnnnn_type_cast=>pnnnn_to_prelp
exporting
pnnnn = wa_p0008
importing
prelp = innnn.
09-17-2008 9:58 PM
Hi Mrunal,
search for user-exit or BADIs for the transaction PA30.
EXIT_SAPFP50M_001
EXIT_SAPFP50M_002
EXIT_SAPMP50A_001
Regards,
Amit R.
09-18-2008 1:11 AM
You need to implement use exit EXIT_SAPFP50M_001, (cmod/smod thing)
and code something like this inside:
IF innnn-infty = '0008'.
call method cl_hr_pnnnn_type_cast=>prelp_to_pnnnn
exporting
prelp = innnn
importing
pnnnn = wa_p0008.
* Assign the values/calculations here
* wa_p0008-yourfield = whatever_you_want. "Change this line
* wa_p0008-yourfield = whatever_you_want. "Change this line
* etc.
* etc.
call method cl_hr_pnnnn_type_cast=>pnnnn_to_prelp
exporting
pnnnn = wa_p0008
importing
prelp = innnn.
09-26-2008 5:59 AM
Hi Thanks all,
I made the suggested changes in ZXPADU02,whcich is the user exit program. But the problem now is I want to populate the changes into the table control available in infotype 0008 for displaying salary breakup, how do i do that ?
11-08-2008 10:07 AM
I have a different problem. I can access some of the screen fields. But I cannot access AMOUNT field. If anyone knows, please help me out...I want to put a value into that AMOUNT field after some calculation.
11-10-2008 2:03 PM
If you are in ECC 6, the best way is using BADI HRPAD00INFTY. There are 3 events, PBO, PAI and IN_UPDATE and you have access to the PA0008 structure, so you can change the fields LGA01, ANZ01, etc within the PAI event.
11-11-2008 1:11 PM
12-03-2008 4:58 AM
Hi Experts,
I have a requirement where in when an action 'Create trip ' is triggered and when all the fields are filled for a custom infotype 9051 and the "save' is clicked a record has to inserted into the it2001 with the begda nad endda of 9051. To achieve this I using the exit ZXPADU02. Will that be helpul and how can go about the code. Plz provide poinetrs.
TIA