cancel
Showing results for 
Search instead for 
Did you mean: 

Issue with customer exit for copying one variable value to another

Former Member
0 Kudos

Hello Gurus,

I need to copy the value of a single value variable into another single customer exit variable.

I coded as below.

WHEN 'customer_exit_var'.

IF I_STEP = 2. "after the popup

LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE

WHERE VNAM = 'user_input_Variable'.

CLEAR L_S_RANGE.

L_S_RANGE-LOW = LOC_VAR_RANGE-LOW.

L_S_RANGE-HIGH = ''.

L_S_RANGE-SIGN = 'I'.

L_S_RANGE-OPT = 'EQ'.

APPEND L_S_RANGE TO E_T_RANGE.

EXIT.

ENDLOOP.

ENDIF.

I used the condition <= for the customer exit variable in the report. But, it is considering only single value, but not all the values <= to the give value.

Please help me in this regard,

Thanks,

Aarthi.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Aarthi,

Could you be more clear.

Thanks

Message was edited by:

Govind Sehgal

Former Member
0 Kudos

Thanks for your immediate response Govind.

My report is restricted based on two dates. Date1 and Date2. Need to consider all records whose dates are <= Date1 and <= Date2.

Date1 and Date2 should have same values. But user inputs only Date1.

So, I created Date1 as Single, User Input Variable restricted the query with <=Date1.

Next I created Date2 as Single, Customer Exit Variable and restrcited the Query with <=Date2.

In CMOD I used the above code to assigne Date1 Value to Date2.

When I execute the report, say I give todays date in the report (Dec, 12, 2007). Date2 has to consider all the values <= Dec 12, 2007. But, in my case it is considering only Dec 12, 2007, but not the before dates.

So, Please help me in solving this problem.

Thanks,

Aarthi.

Former Member
0 Kudos

While writing code in CMOD use 'LE' (Less than or equal to ) instead of "EQ"

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

L_S_RANGE-LOW = LOC_VAR_RANGE-LOW.

L_S_RANGE-HIGH = ''.

L_S_RANGE-SIGN = 'I'.

L_S_RANGE-OPT = <b>'EQ'. -- 'LE'</b> <<----


APPEND L_S_RANGE TO E_T_RANGE.

EXIT.

Regards

VJ

Former Member
0 Kudos

Hi Vijaysarathy,

Thanks for the reply.

Do I have to keep the option LE in the code as well as <= restriction in the query too ??

Thanks,

Aarthi

Former Member
0 Kudos

Aarthi,

Usually in the query we drag the variable we need to restrict with to the particular characteristics. I think that is sufficient and you no need to put restriction as <= in the query as such.

Let me know whether your issue is solved aftr correcting the code..

VJ

Former Member
0 Kudos

Hi Vijayasarathy,

Thanks for your time. It worked out.

I used EQ in the CMOD and <= in the Query restriction.

Thanks,

Aarthi

Answers (0)