08-18-2016 10:59 AM
Dear Experts,
I want to set radio button in info type 0021 based on subtype.
for eg : If the Sub type is 11 – Father then the Gender should be Male and if the Sub type is 12 – Mother, then the Gender should be Female.
Thanks and Regards,
Shardul Tendulkar
08-25-2016 3:57 AM
Hello Shardul:
Maybe you can try this way:
Tcode: CMOD --> Create new project(Z*) --> Assignments enhancements:PBAS0001
--> EXIT_SAPFP50M_001 --> ZXPADU01,
Add below code:
IF INNNN-INFTY = '0021'.
IF INNNN-SUBTY = '11'.
INNNN-DATA1+18(1) = '1'.
ELSEIF INNNN-SUBTY = '12'.
INNNN-DATA1+18(1) = '2'.
ENDIF.
ENDIF.
08-19-2016 4:39 PM
Check this thread
Default gender based on subtype in infotype 0021 | SCN
you've got to implement a BADI Z* in reference to HRPAD00INFTY, then implement a class in order to implement if method in HRPAD00INFTY, these are:
BEFORE_OUTPUT
AFTER_INPUT
IN_UPDATE
Google "HRPAD00INFTY implementation", you should find some help to do it.
Regards
08-21-2016 6:58 AM
Hello,
I tried using HRPAD00INFTY badi.
I am not getting variables / values in global and local parameters in PBO for applying validation
Thanks,
shardul.
08-22-2016 9:21 AM
Take as example BEFORE_OUTPUT method
There are some parameters:
TCLAS
IPSYST
I001P
I503
INNNN
IPREF
In INNNN parameter you should be able to check the infotype you are running.
With a CASE new_innnn-infty you can then focus on the Infotype 0021 with WHEN '0021'
Then you could implement your logic there to check the field SUBTY content and to force field FASEX when applicable.
In method AFTER_INPUT you have NEW_INNN and OLD_INNN.
Let me know.
Thanks.
08-25-2016 3:57 AM
Hello Shardul:
Maybe you can try this way:
Tcode: CMOD --> Create new project(Z*) --> Assignments enhancements:PBAS0001
--> EXIT_SAPFP50M_001 --> ZXPADU01,
Add below code:
IF INNNN-INFTY = '0021'.
IF INNNN-SUBTY = '11'.
INNNN-DATA1+18(1) = '1'.
ELSEIF INNNN-SUBTY = '12'.
INNNN-DATA1+18(1) = '2'.
ENDIF.
ENDIF.