06-11-2008 7:37 AM
Hi all,
I need to keep a dynamic date selection in the selection screen variant for the background processing . The selection has to be from start of the month to current date - 1 . for eg. if the current date is 11th june, then the selection screen should contain 1st june to 10th june .
Thanks & Regards
Magesh Anandan
06-11-2008 7:39 AM
06-11-2008 7:42 AM
Hi,
you mean you are scheduling a variant and in that you want the date like that?
Raj
06-11-2008 7:43 AM
In INTIAliZATION event u can code to check the current date and from thsi calculate the date u want on the selct options , as these are going to be the default in back ground mode user will able run the date .
u can always code if want to initialize in background only check for sy-batch
06-11-2008 7:46 AM
Hi Magesh Anandan,
you may display 2 parameters, both of type date. One of them should be "date from" and the other one "date to".
Then, when saving the variant attributes, check "D: Dynamic date calculation" on column "selection variable". Now you have to populate column "Name of variable (input only using F4)". On the first date parameter ("from"), choose "First day of current month"; on the second date parameter ("to"), choose "Current date +/- ??? days", and enter "-1" when the popup asks you to.
I hope this helps. Kind regards,
Alvaro
06-11-2008 7:53 AM
Dear magesh
use this document to learn how to create dynamic variant
http://www.saptechnical.com/Tutorials/ABAP/DynamicVariant/Procedure.htm
in choose date validation, choose from month start to today.
this will solve your problem
Regards
abhinesh
Edited by: abhinesh mishra on Jun 11, 2008 8:54 AM
06-11-2008 8:03 AM
1> First fill in all the selection screen data including Date and save the data as variant.
2> Give some variant name and description. Select the check box corresponding to the Date range as selection variable (L). Next press push button selection variables in the tool bar.
3> Click on the yellow light corresponds to column D(Stands for Dynamic). It will become green colour.
4>Then press the down arrow at the end of the date range.
5>It will display a popup for various calculations.For your requirement choose 'From month start to today'.
6> Save the Variant.
Reward Points if Helpful.