08-29-2008 1:40 PM
Hii ...
I have a small problem ...
how can i check wether a particular user is authorized to execute a transaction or not ...
the issue is .. i have created a Module pool program ... now i need to have a authority check to execute the transaction..
thanks and regards
chandu reddy
08-29-2008 1:48 PM
Hi Chandu,
Check this link:
http://help.sap.com/saphelp_nw04s/helpdata/en/52/67129f439b11d1896f0000e8322d00/content.htm
Regards,
Chandra Sekhar
08-29-2008 1:44 PM
Hello,
Use the authority-check command.
PARAMETERS carr TYPE spfli-carrid.
AT SELECTION-SCREEN.
AUTHORITY-CHECK OBJECT 'S_CARRID'
ID 'CARRID' FIELD carr
ID 'ACTVT' FIELD '03'.
IF sy-subrc <> 0.
MESSAGE 'No authorization' TYPE 'E'.
ENDIF.
If the user has the authority object associated to his profile, the resul of sy-subrc will be 0.
Regards.
08-29-2008 1:45 PM
Create the transaction in SE93 as a dialog transaction for that module pool program / screen.
To start the program, the (normal) user would need the authority for that transaction (object S_TCODE).
I think if you search for "transaction to start a module pool program" then you would probably also have found some hits....
Cheers,
Julius
08-29-2008 1:48 PM
Hi Chandu,
Check this link:
http://help.sap.com/saphelp_nw04s/helpdata/en/52/67129f439b11d1896f0000e8322d00/content.htm
Regards,
Chandra Sekhar
08-29-2008 2:15 PM
Hey Hiiiii guys ....
Thanks for all ur responses ....issue got resolved ....
thanks and regards
chandu reddy
08-29-2008 2:40 PM
BTW: If you are coding an authority-check statement into your program (as mentioned by David) for object S_TCODE (as mentioned by me - at transaction start), I recommend that you do this by calling function module 'AUTHORITY_CHECK_TCODE' as you might want more than 1 transaction to be able to use this program, but no other.
Cheers,
Julius