Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 9236

Re: Authorisation objects in sap abap hr program

$
0
0

Hi  Joince,

a z authorization object will be created by your basis team, where they will assign the respected

tcodes only to those user for which you wants authorization.

 

You have to write your code logic in your program to validate it.

If it will true then only those user will access that transaction.

 

You have to code something like this, please change it according to your tcode.

 

  IF SY-TCODE = 'your tcode'.

    AUTHORITY-CHECK OBJECT 'Zobject'

                                 ID 'ACTVT' FIELD '01'

                               id 'ACTVT' field '02'

                               id 'ACTVT' field '03'

                              

   IF SY-SUBRC EQ 0.

    ELSE.

 

MESSAGE 'YOU ARE NOT AUTHORISED FOR THIS Tcode' TYPE 'E'.

    

          ENDIF.

    ENDIF.

 

 

 


Viewing all articles
Browse latest Browse all 9236

Trending Articles