Tuesday, November 9, 2010

How to populate and use user exit varible

Create and Populate User Exit Variable with default date as current date.

Create a variable(ex: cur_date) on requrired characteristic with Processing type "Customer Eixt" and check the check box for ready for input(if this variable need in selection screen).

Step 2
Goto T Code : CMOD and provide appropriate Project and choose components and click on display.

Double click on exit "EXIT_SAPLRRS0_001" you can see include "ZXRSRU01", double click on include.

Sample code to populate.

Data : l_p_range_SSS TYPE rrrangesid.
IF I_STEP = 1.
l_p_range_SSS-Low = sy-datum.
l_p_range_SSS-Sign = 'I'.
l_p_range_SSS-Opt = 'EQ'.
APPEND l_p_range_SSS TO e_t_range.

The following values are valid for I_STEP:·
I_STEP = 1
Call up takes place directly before variable entry·
I_STEP = 2
Call up takes place directly after variable entry. This step is only started up when the same variable could not be filled at I_STEP=1.·
I_STEP = 3
In this call up, you can check the values of the variables. Triggering an exception (RAISE) causes the variable screen to appear once more. Afterwards, I_STEP=2 is also called up again.·
I_STEP = 0The enhancement is not called from the variable screen. The call up can come from the authorization check or from the Monitor.

No comments:

Post a Comment