Quantcast
Channel: SCN : All Content - ABAP Development
Viewing all articles
Browse latest Browse all 8332

Authorization Check

$
0
0

Hi All,

 

I have a requirement where I need to update the authorization check for the FB02 T code...

task is :

Insert authority check prior to calling Transactions or program

 

Program is ( a part where i need to update the code):

 

set parameter if 'BLN' field accrual_belnr

set parameter if 'BUK' field accrual_bukrs

set parameter if 'GJR' field accrual_gjahr

call transaction 'FB02' and skip first screen.   (Here I need to update the Auth check)

 

I have written a Authorization check code like:

 

AUTHORITY-CHECK OBJECT 'S_FB02'

           ID 'belnr' FIELD accrual_belnr

           ID 'gjahr' FIELD accrual_gjahr

           ID 'bukrs' FIELD accrual_bukrs.

        IF  sy-subrc = 0.

        MESSAGE 'No authorization' TYPE 'E'.

ELSE.

  MESSAGE 'Congrats! You are authorized' TYPE 'S'.

ENDIF.

 

Is my code is correct or do i need to make any changes??  Wht is the existing tcode call?

 

kindly help with this.

 

Regards,

Kiran


Viewing all articles
Browse latest Browse all 8332

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>