‎2007 Aug 06 6:54 AM
‎2007 Aug 06 6:56 AM
Hi,
the purpose of Initialization and default is same. It just a two different ways for giving a default value to a variable.
regards,
Navneeth K.
‎2007 Aug 06 6:57 AM
‎2007 Aug 06 7:01 AM
Hi,
Though the function of both seems to be the same, there is difference in their nature and use. In INITIALIZATION.
Refer to the below threads
http://help.sap.com/saphelp_nw04/helpdata/en/c0/98038ce58611d194cc00a0c94260a5/content.htm
Reward if helpful
Regards,
K
‎2007 Aug 06 7:01 AM
Hi,
Initialization - This is the first event to be fired
default - you declare it in the data statement or in the selection screen
Regards
Arun
‎2007 Aug 06 7:06 AM
Hi...
There is a difference between the DEFAULT (Used in PARAMETERS and
SELECT-OPTIONS) and INITIALIZATION event which is triggered before loading the selection screen.
For Eg We want to Declare a PARAMETER for a Date input and provide the DEFAULT VALUE as Yesterday.
EG:
PARAMETERS : P_DATE TYPE SY-DATUM DEFAULT SY-DATUM - 1.
**This is not allowed bcoz DEFAULT cannot expressions.
We can acheive this only using INITIALIZATION event
EG:
PARAMETERS : P_DATE TYPE SY-DATUM.
INITIALIZATION.
P_DATE = SY-DATUM - 1.
<b>Reward if Helpful.</b>
‎2007 Aug 06 7:18 AM
hi,
initialization is the second event in report execution by sap. 1st event is LOAD-OF-PROGRAM which is default event.
Initialization event is useful for assigning default values to select options
Default keyword is used for assigning default values to varaiables, parameters.
if helpful reward some points.
with regards,
Suresh Aluri.