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

Selection-Screen

Former Member
0 Likes
691

Hi Frendz, i want to display '001' in lower and '007' in hger , this is my code , but its giving run time error .

tables : coep.

data : month(3) type n,

month1(3) type n.

month = sy-datum+4(2).

month1 = month - 1.

select-options : s_perio for coep-perio default '001' to 'month1'.

i want to display '001' in lower and current month - 1 in higher ie 7.

can u pls help me ?

6 REPLIES 6
Read only

Former Member
0 Likes
663

Hello Srini,

Use like this.

In INITIALIZATION EVENT,

s_perio-low = '001'.

s_perio-high = sy-datum+4(2) - 1.

If useful reward,

vasanth

Read only

Former Member
0 Likes
663

Hi srini,

1. we have to use INITIALIZATION EVENT.

2. just copy paste, and it will show

3.

report abc.

Tables : coep.

data : month(3) type n,

month1(3) type n.

*----


select-options : s_perio for coep-perio .

*----


INITIALIZATION.

month = sy-datum+4(2).

month1 = month - 1.

S_PERIO-LOW = '001'.

S_PERIO-HIGH = MONTH1.

APPEND S_PERIO.

regards,

amit m.

Read only

Former Member
0 Likes
663

Hi,

THis is the corrected code. check it.

REPORT  ZTESt     .

tables : coep.

select-options : s_perio for coep-perio .

initialization.
data : month(3) type n,
month1(3) type n.

month = sy-datum+4(2).


month1 = month - 1.

s_perio-sign = 'I'.
s_perio-option = 'BT'.
s_perio-low = '001'.
s_perio-high = month1.
append s_perio.

regards

vijay

Read only

Former Member
0 Likes
663

Hi Srini

Do the coding in Initialization evenT and it will work for you.

Kind Regards

Eswar

Note: Reward for helpful answers.

Message was edited by: Eswar Rao Boddeti

Read only

Former Member
0 Likes
663

data : x type i.

x = sy-datum+4(2).

x = x-1.

s_perio-sign = 'I'.

s_perio-option = 'EQ'.

s_perio-low = '001'.

s_perio-high = x.

APPEND s_perio.

CLEAR s_perio.

Message was edited by: Ashok Parupalli

Read only

Former Member
0 Likes
663

put like this.

REPORT YTEST_EMAIL2 .

tables : coep.

data : month(3) type n,

month1(3) type n.

select-options : s_perio for coep-perio.

initialization.

break-point.

month = sy-datum+4(2).

month1 = month - 1.

s_perio-sign = 'I'.

s_perio-option = 'BT'.

s_perio-low = '001'.

s_perio-high = month1.

append s_perio.

Regards

Prabhu