Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Parameters

Former Member
0 Likes
1,049

Hi,

I would like to know more about parameters. what i want to do is to be able to use parameters to decide if a logged in use is from a certain department. Say Department 1 or 2. When a program is executed, the program will know from the user profile that he/she is from department 1. Any idea how to go about this? Thanks.

Regards,

r3venant

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
891

Hi Revath,

you can create parameter id 3 ways

1. Goto SM30 for table TPARA and create it

2. you can go to SE80,

Other object button -> More... tab -> SET/GET parameter ID.

Enter a name and press the create button.

3. use FM RS_PARAMETER_ADD

6 REPLIES 6
Read only

Former Member
0 Likes
891

Hi R3venant,

Yes you can do.Use sy-uname to get the logged in user name.

Then Check the table pa0105 and get his employee number.

get his position from pa0001 table and get the corrs dept.

Rgds,

Jothi.P

  • let me know the outcome.

Read only

amit_khare
Active Contributor
0 Likes
891

This can be done with a piece of code.

For SY-UNAME extract PERNR from PA0105 SUBTY = '0001'.

For that PERNR extract ORGEH from PA0001. this is your Department.

Regards,

Amit

Reward all helpful replies.

Read only

former_member194669
Active Contributor
0 Likes
891

Check for user profile transaction SU3>User profile> Own Data, May be user can maintained the dept value here

aRs

Message was edited by:

aRs

Read only

Former Member
0 Likes
891

Thanks guys, Um. If lets I want to create my own custom parameter ID to hold the deparment number. How do i go about it? Thanks again

Regards,

r3venant

Read only

Former Member
0 Likes
892

Hi Revath,

you can create parameter id 3 ways

1. Goto SM30 for table TPARA and create it

2. you can go to SE80,

Other object button -> More... tab -> SET/GET parameter ID.

Enter a name and press the create button.

3. use FM RS_PARAMETER_ADD

Read only

Former Member
0 Likes
891

Ok thanks alot guys. I'll work on it. Thanks again

Regards,

r3venant