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 design

Former Member
0 Likes
315

Hi frnds,

Can anyone hlep me how to write the selection screen for the stuff below.

Zavail(program name) , create parameter selection to run by travel dates. Must have ability to run nightly (travel date range: tomorrow’s date to 60 days later) and weekly (travel date range: 61days after of tomorrow to 6 month after of today’s date).

help me frnds.

regards,

sanjay

1 REPLY 1
Read only

Former Member
0 Likes
286

Try this code...


"nightly (travel date range: tomorrow’s date to 60 days later) and
"weekly (travel date range: 61days after of tomorrow to 6 month after of today’s date).

SELECT-OPTIONS : s_nigtly FOR sy-datum.
SELECT-OPTIONS : s_weekly FOR sy-datum.

INITIALIZATION.
s_nigtly-sign = 'I'.
s_nigtly-option = 'BT'.
s_nigtly-low = sy-datum + 1. "tommorrows date
s_nigtly-high = sy-datum + 60. "60 days later.
APPEND s_nigtly.

s_weekly-sign = 'I'.
s_weekly-option = 'BT'.
s_weekly-low = s_nigtly-low + 61 . "61days after of tomorrow

CALL FUNCTION 'MONTH_PLUS_DETERMINE'
  EXPORTING
    months        = '6'
    olddate       = sy-datum
 IMPORTING
   NEWDATE       = s_weekly-high. "6 month after of today’s date
APPEND s_weekly.