Ansicht
Dokumentation

EXIT_RPCTRCU0_002 - Customer exit for determining values in Box13 of W2 in RPCTRCU0.

EXIT_RPCTRCU0_002 - Customer exit for determining values in Box13 of W2 in RPCTRCU0.

CL_GUI_FRONTEND_SERVICES - Frontend Services   RFUMSV00 - Advance Return for Tax on Sales/Purchases  
This documentation is copyright by SAP AG.
SAP E-Book

Functionality

This user exit allows you to create the logic for selecting the Retirement Plan (Pension & Deferred), Statutory Employee, and Third Party Sick Pay in Box 13 of the W-2 form, according to your needs.

If the employee meets the criterion, pass value 'Y' to the return value If the employee does not meet the criterion, pass value 'N' to the return value.

If the return value is 'Y' then the check boxes on W2 box 13 will be marked.

Example

The following examples illustrate how the code can be written.

You can adopt these examples to make your own code changes and add up the extra functionality depending on your requirements or add your own code

tables : T503, T5UT1.

infotypes : 0041.

data : l_abart like t503-abart,

work_day type i,

rec_found type c value ' '.

data: begin of tmp_p0041 occurs 10.

include structure p0041.

data: end of tmp_p0041.

call function 'HR_READ_INFOTYPE'

exporting

* TCLAS = 'A'

pernr = pernr

infty = '0041'

begda = begda

endda = endda

* IMPORTING

* SUBRC =

tables

infty_tab = tmp_p0041

exceptions

infty_not_found = 1

others = 2.

*---Assume that the pension is marked if the employee either belongs to *---any of these groupings or has one year of service in the *---organization.

case taxty.

when 'W25C'. "Pension

loop at pp0001 where begda <= endda and

endda >= begda.

if ( pp0001-persk = 'U1' or

pp0001-persk = 'U5' ) and

pp0001-bukrs = '3000'.

value = 'Y'.

rec_found = 'Y'.

else.

rec_found = 'N'.

endif.

if rec_found = 'N'.

loop at pp0000 where begda <= endda and

endda >= begda.

if pp0000-stat2 = '3'.

loop at tmp_p0041 where begda <= endda and

endda >= begda.

if not tmp_p0041-dat01 is initial.

work_day = ( endda ) - ( tmp_p0041-dat01)

endif.

endloop.

endif.

endloop.

if work_day >= 364.

value = 'Y'

endif.

endif.

when 'W25G'. "Deferred Compensation

*--- Assume that the deferred compensation is paid only for the *---salaried employees, (not a real business scenario, but an example *---to show how we can select from the tables )

*---The personnel calculation rule from the table T503 will help us in *---determining the hourly/salaried employee. SAP standard value for *---salaried employee is '3'.

loop at pp0001 where begda <= endda and

endda >= begda.

select single abart from t503 into l_abart where

persg = pp0001-persg and

persk = pp0001-persk.

if l_abart = '3'.

value = 'Y'.

endif.

endloop.

when 'W25A'. "Statutory employee.

*

*

*

when 'W25H'. "Third Party Sick Pay.

*

*

*

endcase.

Further information

Refer to the Tax Reporter User Guide (located at http://service.sap.com/hrusa) and Note 436978 "YE 2001 Phase II - Legal changes, enhancements" for more instructions.





Parameters

BEGDA
ENDDA
PERNR
PP0000
PP0001
PP0002
TAXTY
VALUE

Exceptions

Function Group

XCU0

BAL Application Log Documentation   Vendor Master (General Section)  
This documentation is copyright by SAP AG.

Length: 4710 Date: 20240523 Time: 080911     sap01-206 ( 55 ms )