I am modifying the payslip.
Here in input screen we r using plant option.
my problem is if the person shifts from one plant to another plant then the payslip of that person must be latest plant payslip.
but if the end user takes payslip of the persons according to plant wise then that particular persons payslip is comming in both the plants.
I am using the following FM.
CALL FUNCTION 'LAST_DAY_OF_MONTHS'
DAY_IN = W_BEGDA
LAST_DAY_OF_MONTH = W_ENDDA.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
is there any function module like a person joining the middle of the month
he joins on 15 th of the month and it has to calculate the last day ofthe month.