‎2005 Dec 07 1:38 PM
Hi all,
I have date field as selectoptions.
Based on the data provided on selectoption i need to create one more selectoption with period.
ex:
date 20050612 to 20050908
need to create new selectoption.
period 200506 to 200509
please advise me.
with regards
chandu.
‎2005 Dec 07 1:52 PM
after entering the date press enter , at selection screen event fires in that you fill the dates for the other select options.
at selection-screen.
fill period.
regards
vijay
‎2005 Dec 07 1:43 PM
Hi sai,
selectoption: period like integer.
This would create ur select options field from - to all when u execute it.If u want the constants in select options then save that screen as a variant,so that it can be reused when u execute it next time.
Hope this helps u,
Regards,
Nagarajan.
‎2005 Dec 07 1:45 PM
if it is for using for selection in the program , you can add the "NO_DISPLAY" extension to the select-option(2nd one) defintion and it will not be displayed to the user...
then once the user has entered the value..in the event at selection-screen, you can append the entries into the select-option(2nd)...
you can also use Ranges for this..
‎2005 Dec 07 1:52 PM
ranges: so_spmon type ISELLIST-MONTH .
loop at so_date .
clear so_spmon .
so_spmon-low = so_date-low(6) .
so_spmon-high = so_date-high(6) .
so_spmon-option = so_date-option .
so_spmon-sign = so_date-sign .
append so_spmon .
endloop .
Regards
Alexandre Nogueira
‎2005 Dec 07 1:52 PM
after entering the date press enter , at selection screen event fires in that you fill the dates for the other select options.
at selection-screen.
fill period.
regards
vijay
‎2005 Dec 07 2:05 PM
try that:
SELECT-OPTIONS : s_date FOR sy-datum DEFAULT '20050612' TO '20050908'.
SELECT-OPTIONS : s_period FOR dkkop-buper.
*
AT SELECTION-SCREEN OUTPUT.
REFRESH s_period.
LOOP AT s_date.
MOVE-CORRESPONDING s_date TO s_period.
COLLECT s_period.
ENDLOOP.regards Andreas
‎2005 Dec 07 1:59 PM
at selection-screen.
period-low = date-low(6) .
peiod-high = date-high(6) .
period-option = 'BT'.
period-sign = 'I' .
append period .
‎2005 Dec 07 2:15 PM
declare 2 select-options in the selection screen.
In INITIALIZATION. make 2 select-option as no-display.
when user enters date in the first select-option and press enter, do following.
select-option2-low = select-option1-low+0(6).
select-option2-high = select-option1-high+0(6).
append select-option2.
In the at selection-screen, make this field visible and the program works normally.
Hope this will work for u.
‎2005 Dec 07 2:19 PM