Step1:Creating Variants for SAP ABAP programs Normal
Variant is a concept of saving a set of input fields with values with a particular name, so that we can use the same set of inputs next time, the below is the example of creating variants in SAP ABAP programs.
Create a program with a selection-screen.
REPORT ZSAPN_DYNAMICDATE. DATA LV_DATUM TYPE DATUM. PARAMETERS P_DATE TYPE DATUM. SELECT-OPTIONS S_DATE FOR LV_DATUM.
Provide some input values, click on save button.
How to use variant in SAP ABAP programs
Go to the program selection screen, you will find variant icon, click on variant icon.
Step2:Dynamic date in variant for parameters Normal
Go to report selection screen.
Provide some input values, click on save button.
Press F4 on selection variable input of parameter date,select D:Dynamic Date Calculation, enter.
Press enter, press F4 on name of variable, double click on current date +/- ??? days.