on 05-17-2011 4:16 PM
SDN members,
I've the following scenario and would need your help to find a solution.
1. A Z tables contains a mapping for the user names & institution ID's.
2. The user when executing the query should see only the values that he is mapped to in the Z table.
3. I created a Customer Exit Variable and populated the values allowed for the user.
4. On the selection screen the user is seeing the values he is allowed to see. ( he might see 2 values for example).
5. However, the user can enter any other value.
Question: How can I limit the user to the values in the selection such that the user cannot enter any other value ?
Also, handling the above scenario with the authorization objects is out of question for my case.
Any help is appreciated.
regards
AHS.
Hi ,
You can always use i_step = 3 mode in CMOD code to put validations on your BI selection screen .
See a sample code written below by me . You can modify it to your requirement :
here my aim is , i should not allow user to execute the report when the year in the calmonth is less than 2008 .
In this code RRMS_MESSAGE_HANDLING is a FM, which is used to throw an exception . You can type your own message in I_MSGV1, which will be displayed to the user .
data : zcmonth(6) type c.
data :year(4) type c.
data : year1 type i.
IF I_STEP = 3.
CLEAR : zmonth
LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE WHERE VNAM = 'zcmonth'.
zcmonth = LOC_VAR_RANGE-LOW.
year = zcmonth+0(4).
year1 = year .
If year <2008 .
CALL FUNCTION 'RRMS_MESSAGE_HANDLING'
EXPORTING
I_CLASS = 'RSBBS'
I_TYPE = 'E'
I_NUMBER = '000'
I_MSGV1 = 'Year is less than 2008'.
RAISE no_replacement.
ENDIF.
ENDLOOP.
ENDIF.
Hope the above reply was helpful.
Kind Regards,
Ashutosh Singh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.