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

regarding select-options.

Former Member
0 Likes
1,319

Hi All,

There are 2 date fields( posting date and Report. date ) on the selection input screen with select-options. As soon as i enter value in TO field of posting date i want the same date to be appear in the TO field of Report date.

Thnx.

13 REPLIES 13
Read only

Former Member
0 Likes
1,273

Hi,

You can use AT SELECTION-SCREEN Event.

S_DATE1-HIGH = S_DATE2-HIGH.

Regds,

Anil

Edited by: Anil Katoch on Jul 22, 2009 7:58 AM

Read only

0 Likes
1,273

but i need to hit enter button for that then date will appear. I don't want to hit any button but it should appear there as soon as i enter date in one field.

Read only

0 Likes
1,273

Hi,

I think you have to use Module Pool program for that.

Thanks and best Regards,

Suresh

Read only

0 Likes
1,273

i dont think this is possible. you have to trigger atleast an event for this. and typing wont trigger any event.

atleast a check box or radio button or an enter some thing has to be pressed.

Read only

0 Likes
1,273

I think 'Enter' has to be hit to trigger 'At selection-screen' event.

Without any trigger no event can execute in ABAP.

Read only

0 Likes
1,273

Not possible in SAP. Untill unless you don not press enter, how system got your command.

Its better to initialize at initilization event to some variable and remove it from selection screen.

Regds,

Anil

Edited by: Anil Katoch on Jul 22, 2009 8:19 AM

Read only

awin_prabhu
Active Contributor
0 Likes
1,273

Hi,

Use At Selection-screen event.

Use code like below.

SELECT-OPTIONS: s_ersda FOR mara-ersda,

s_laeda FOR mara-laeda.

AT SELECTION-SCREEN.

IF s_ersda-high IS NOT INITIAL.

clear s_laeda[].

APPEND s_ersda TO s_laeda.

ENDIF.

Edited by: Sap Fan on Jul 22, 2009 7:59 AM

Read only

RaymondGiuseppi
Active Contributor
0 Likes
1,273

1 - Add an option NO-EXTENSION to the parameters

2 - In the AT SELECTION-SCREEN copy the -high value from the first parameter to the second

The user must press ENTER, cause the PBO wont be triggered by filling a SELECT-OPTIONS high value.

Regards,

Raymond

Read only

Former Member
0 Likes
1,273

Hello Frn,

SELECT-OPTIONS : data1 for sy-datum .

SELECT-OPTIONS : data2 for sy-datum .

AT SELECTION-SCREEN OUTPUT .

data2-low = data1-low .

insert data2 index 1 .

thanks and regards .

Priyank

Read only

0 Likes
1,273

priyank,

i dont think this code of yours works without an Enter button or any event triggering button being pressed.

and your code wont solve this question i guess

Read only

0 Likes
1,273

Hello Soumya prakash ...

you are absoloutly right .....but we have to do something to trigger the event ....and that is done by pressing ENTER .

regards ..

Priyank

Read only

Former Member
0 Likes
1,273

Hello Frn's ...

you have to press enter....for desired output .

Regards ...

Priyank

Read only

viquar_iqbal
Active Contributor
0 Likes
1,273

Hi

Use this code

DATA : a TYPE i .
DATA b TYPE i.

SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME .
SELECT-OPTIONS abc FOR a .
SELECT-OPTIONS bca FOR b.
SELECTION-SCREEN END OF BLOCK b1.

AT SELECTION-SCREEN OUTPUT.
  CASE sy-ucomm.
    WHEN ' ' .
          bca = abc.

  ENDCASE.

START-OF-SELECTION.

  b = 2.

END-OF-SELECTION.
  WRITE: a NO-ZERO , b.

But in the event At-selection screen output you need to loop at modify screen .

You can assign a modif-id to select-options.

The value entered in select-option abc is moved to selection option bca at the press of enter but since i have not used modify screen statement its not displaying on the screen .

Once you do that this would resolve your issue.

Thanks

Viquar Iqbal