‎2008 Apr 16 9:16 AM
Hi,
I have a doubt that how many times the event INITIALIZATION
triggers in a program. Why?
Thanks in advance.
Zakir.
‎2008 Apr 16 9:18 AM
Hi
Just only one time: before loading the selection-screen
Max
‎2008 Apr 16 9:18 AM
Hi
Just only one time: before loading the selection-screen
Max
‎2008 Apr 16 9:19 AM
hi
when u press f8 or execute INITIALIZATION event will trigger.
but after tht it will not trigger in prog.so only once time it will trigger whn u press f8.
correct me if m wrong.
‎2008 Apr 16 9:20 AM
Hi,
You can use any number of times.
Example:
parameters: p_text(20).
initialization.
p_text = 'Hello'.
initialization.
initialization.
initialization.
p_text = 'Hi'.
initialization.
initialization.
Note: p_text contains only 'Hi'.
‎2008 Apr 16 9:53 AM
Hi, of course u may have many initalization events in your program, but they are triggered for the first time i..e before selection screen.
‎2008 Apr 16 9:59 AM
Hi, of course u may have many initalization events in your program, but they are triggered for the first time i..e before selection screen.
The driver program will scan for all events and executes all the initialization events on the order they have declared
Its poor practice to split same events , however they are valid .
‎2008 Apr 16 9:21 AM
It triggers only once except the case highleted in NOTE below :
INITIALIZATION.
Effect
This event keyword defines an event block whose event is triggered by the ABAP runtime environment during the flow of an executable program, directly after LOAD-OF-PROGRAM and before the selection screen processing of any existing standard selection screen. This gives you the one-time opportunity to initialize the input fields of the selection screen, including those defined in the logical database linked with the program.
Note
When an executable program defines a standard selection screen, it is called again by the ABAP runtime environment after execution, which triggers the INITIALIZATION event again. In this case, initializing parameters or selection criteria of the selection screen has no effect, because they are automatically supplied with the preceding user inputs from the selection screen during the selection screen event AT SELECTION-SCREEN OUTPUT. To explicitly initialize the selection screen for each call, you must use the event AT SELECTION-SCREEN OUTPUT.
do reward if helpful
‎2008 Apr 16 9:21 AM
Hi
INITIALIZATION is triggered only once in report.
Initialization : triggered when the report is loaded in memory.
‎2008 Apr 16 9:27 AM
Hi,
Initialization event is triggered only once before the selection screen comes. The selection parameter values given by default in the data declaration are overide by the values in the initialization event.
Reward.
‎2008 Apr 16 9:31 AM
Hi,
Initialization event triggers only once before the selection screen. Using the event initialization we are giving default values to the selection screen feilds.
Thanks
Sarada
‎2008 Apr 16 9:33 AM
Hi,
It triggers only one time. This event is triggered when you execute your program for the first time i.e., before selection screen is displayed.
Regards,
Bhaskar
‎2008 Apr 16 10:07 AM
the event is triggered once when you execute the program.
but if your prog has a selection screen the event is triggered again when you press back button
but if you change the values on selection screen other than you define in initialization they are kept the same as screen fields have seperate memory.
ex : you initialized s_kunnr for 1000 to 1003
but while executin tou changed to 1 to 100
ater execution when you press back button selection-screen reappears but you will not have the default values you have 1 to 100
regards
prasanth