<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: REPORT EVENTS in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833797#M663476</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 27 Sep 2007 05:48:32 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-09-27T05:48:32Z</dc:date>
    <item>
      <title>REPORT EVENTS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833791#M663470</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;if any body can help me to know the report events and what is the importance of each report event,pls explain in detail&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Sep 2007 15:38:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833791#M663470</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-26T15:38:00Z</dc:date>
    </item>
    <item>
      <title>Re: REPORT EVENTS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833792#M663471</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The different events in a report Program are:&lt;/P&gt;&lt;P&gt;Load-of-program&lt;/P&gt;&lt;P&gt;Triggers the associated event in an internal session after loading a program of type 1, M, F, or S. Also runs the associated processing block once and once only for each program and internal session. The processing block LOAD-OF-PROGRAM has roughly the same function for an ABAP program of type 1, M, F or S as a constructor has for classes in ABAP Objects&lt;/P&gt;&lt;P&gt;Initialization.&lt;/P&gt;&lt;P&gt;This event is executed before the selection screen is displayed .&lt;/P&gt;&lt;P&gt;Initialization of all the values. &lt;/P&gt;&lt;P&gt;You can assign different values other than the values defaulted on the selection screen .&lt;/P&gt;&lt;P&gt;You can fill your selection screen with some values at runtime.&lt;/P&gt;&lt;P&gt;At Selection-Screen.&lt;/P&gt;&lt;P&gt;The event is processed when the selection screen has been processed (at the end of PAI ). &lt;/P&gt;&lt;P&gt;Validation &amp;amp; Checks of inputted values happen here&lt;/P&gt;&lt;P&gt;Extras :&lt;/P&gt;&lt;P&gt;&amp;#133;ON VALUE-REQUEST FOR psel_low_high . &lt;/P&gt;&lt;P&gt;The pushbutton for F4 (Possible entries) appears beside the appropriate field. &lt;/P&gt;&lt;P&gt;... ON HELP-REQUEST FOR psel_low_high &lt;/P&gt;&lt;P&gt;. ... OUTPUT &lt;/P&gt;&lt;P&gt;This event is executed at PBO of the selection screen every time the user presses ENTER&lt;/P&gt;&lt;P&gt;Start-of-Selection.&lt;/P&gt;&lt;P&gt;Here the program starts selecting values from tables.&lt;/P&gt;&lt;P&gt;End-of-selection.&lt;/P&gt;&lt;P&gt;After all the data has been selected this event writes the data to the screen.&lt;/P&gt;&lt;P&gt;Interactive Events&lt;/P&gt;&lt;P&gt;Used for interactive reporting. It is used to create a detailed list from a basic list.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Events in an ABAP/4 Report Program&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Start-Of-Selection&lt;/P&gt;&lt;P&gt;Processing block is executed after processing the selection screen&lt;/P&gt;&lt;P&gt;All the data is selected in this block.&lt;/P&gt;&lt;P&gt;All the main processing on the data except for interactive reporting is handled in this block.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;End-Of-Selection&lt;/P&gt;&lt;P&gt;Data which is selected and has been processed is printed to the screen in this block.&lt;/P&gt;&lt;P&gt;List Processing happens in this block&lt;/P&gt;&lt;P&gt;Top-of-Page.&lt;/P&gt;&lt;P&gt;New-Page.&lt;/P&gt;&lt;P&gt;End-of-Page.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Events during List Processing&lt;/P&gt;&lt;P&gt;Top-of-Page.&lt;/P&gt;&lt;P&gt;Triggered by the first write statement in the program&lt;/P&gt;&lt;P&gt;It is used to have a standard header in the program for all the pages.&lt;/P&gt;&lt;P&gt;TOP-OF-PAGE is only executed before outputting the first line on a new page &lt;/P&gt;&lt;P&gt;New-Page.&lt;/P&gt;&lt;P&gt;Can be used when one wants to display different data on different pages&lt;/P&gt;&lt;P&gt;Terminates the current page and continues output on a new page.&lt;/P&gt;&lt;P&gt;Will not trigger the Top-of-Page or End-of-Page. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;End-of-Page.&lt;/P&gt;&lt;P&gt;It is used to have a standard footer for all the pages.&lt;/P&gt;&lt;P&gt;Triggered by the program if the number of records exceed the line-count of the program.&lt;/P&gt;&lt;P&gt;****************************************************&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Report Events&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is the order of execution in Classical/Interactive Report Events&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Classical Reports&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reports which are properly formatted (header, footer, page numbers etc.,) with the help of one or more external events like top-of-page,end-of-page etc., are called as CLASSICAL REPORTS.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Standard list.&lt;/P&gt;&lt;P&gt;Output of Report program is nothing but Standard list. It consists of one continuous page of 60,000 lines.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To restrict number of lines per page.&lt;/P&gt;&lt;P&gt;Report Zxxxxx line-count 25.&lt;/P&gt;&lt;P&gt;OR&lt;/P&gt;&lt;P&gt;Report Zxxxxx line-count 25(3).&lt;/P&gt;&lt;P&gt;( In this case 3 lines are reserved for footer)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To restrict Output width.&lt;/P&gt;&lt;P&gt;Report Zxxxx line-size 125.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To suppress standard page heading.&lt;/P&gt;&lt;P&gt;Report Zxxxx no standard page heading&lt;/P&gt;&lt;P&gt;Above all at a time:&lt;/P&gt;&lt;P&gt;Report Zxxxx line-count 25(3) &lt;/P&gt;&lt;P&gt;line-size 125&lt;/P&gt;&lt;P&gt;no standard page heading.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Screen Events List Events&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Initialization. Start-of-selection &lt;/P&gt;&lt;P&gt;At selection-screen. Top-of-page.&lt;/P&gt;&lt;P&gt;At selection-screen on &amp;lt;field&amp;gt;. End-of-page.&lt;/P&gt;&lt;P&gt;End-of-selection.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We can initialize the selection-screen with calculated default values under this event.&lt;/P&gt;&lt;P&gt;Initialization.&lt;/P&gt;&lt;P&gt;s_date-high = sy-datum.&lt;/P&gt;&lt;P&gt;s_date-low = sy-datum - 15.&lt;/P&gt;&lt;P&gt;Append s_date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We can validate all the inputs on selection screen fields under this event.&lt;/P&gt;&lt;P&gt;At selection-screen.&lt;/P&gt;&lt;P&gt;If s_carrid-low is initial or &lt;/P&gt;&lt;P&gt;s_connid-low is initial or&lt;/P&gt;&lt;P&gt;s_date is initial.&lt;/P&gt;&lt;P&gt;&amp;lt; ... code for validation... &amp;gt;.&lt;/P&gt;&lt;P&gt;Endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We can validate a particular field input on selection screen under this event.&lt;/P&gt;&lt;P&gt;At selection-screen on s_carrid.&lt;/P&gt;&lt;P&gt;If s_carrid-low &amp;lt; &amp;gt; &amp;#145;LH&amp;#146;.&lt;/P&gt;&lt;P&gt;&amp;lt;&amp;#133; code for validation&amp;#133;&amp;gt;&lt;/P&gt;&lt;P&gt;Endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If any of the other event comes before&lt;/P&gt;&lt;P&gt;&amp;#145;Select&amp;#133;Endselect.&amp;#146; statements, then to break&lt;/P&gt;&lt;P&gt;that event, we require this S-O-S event.&lt;/P&gt;&lt;P&gt;Start-of-selection.&lt;/P&gt;&lt;P&gt;Select * from &amp;#133;&amp;#133;&lt;/P&gt;&lt;P&gt;&amp;#133;&amp;#133;&amp;#133;&amp;#133;&lt;/P&gt;&lt;P&gt;Endselect.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If we need some portion of the output (like&lt;/P&gt;&lt;P&gt;column headings) to appear in all the pages,&lt;/P&gt;&lt;P&gt;then we use this event.&lt;/P&gt;&lt;P&gt;Top-of-page.&lt;/P&gt;&lt;P&gt;Write:/ &amp;#145;Carrier&amp;#146;,10 &amp;#145;Connection&amp;#146; 20 &amp;#145;Date&amp;#146;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If there is no external output statement before&lt;/P&gt;&lt;P&gt;&amp;#145;Top-of-page&amp;#146; event, then this event will not &lt;/P&gt;&lt;P&gt;work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Once the cursor reaches the last line of the &lt;/P&gt;&lt;P&gt;page, automatically this event will be triggered.&lt;/P&gt;&lt;P&gt;Report Zxxx line-count 25(3).&lt;/P&gt;&lt;P&gt;In this case line numbers 23, 24 and 25 are &lt;/P&gt;&lt;P&gt;reserved for footer.&lt;/P&gt;&lt;P&gt;Once the cursor reaches 23rd line, this event&lt;/P&gt;&lt;P&gt;will be triggered.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;End-of-page.&lt;/P&gt;&lt;P&gt;Write:/ sy-uline(75).&lt;/P&gt;&lt;P&gt;Write:/ &amp;#145;This is end of page:&amp;#146;,sy-pagno.&lt;/P&gt;&lt;P&gt;Write:/ sy-uline(75).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This event is used for concluding part of List.&lt;/P&gt;&lt;P&gt;End-of-selection.&lt;/P&gt;&lt;P&gt;Write:/ &amp;#145;This is end of the Report&amp;#146;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Interactive Report&lt;/P&gt;&lt;P&gt;A simple report or even a classical report displays a clustered list with all the requested output at one go. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What ever it is displayed, it is final. That means, the user can not interact with with that list.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A simple report or even a classical report displays a clustered list with all the requested output at one go. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What ever it is displayed, it is final. That means, the user can not interact with with that list.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the interactive reports, we can create as many as 21 lists. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The first list is called &amp;#145;Basic list&amp;#146; and all the successive lists are called &amp;#145;Secondary lists&amp;#146;. Each list is again an interactive.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The Basic list is not deleted when secondary list is created. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A secondary list may either overlay the basic list or appear in an additional dialog window on the same screen.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The system variable associated with list number is &amp;#145;SY-LSIND&amp;#146;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For basic list SY-LSIND = 0 and for secondary lists, SY-LSIND varies from 1 to 20.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;User can interact with the list by the following ways.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Double clicking or single click and pressing F2 (function key) or single click with &amp;#145;hotspot on&amp;#146;.&lt;/P&gt;&lt;P&gt;OR&lt;/P&gt;&lt;P&gt;Selecting from menu bar or from application tool bar.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;All the events used in classical reports can be used in Basic List.&lt;/P&gt;&lt;P&gt;The event &amp;#145;End-of-page&amp;#146; can be used in Secondary Lists also.(the other six events can not be used in secondary lists)&lt;/P&gt;&lt;P&gt;You can not place &amp;#145;select-options&amp;#146; in secondary lists.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The following additional events are &lt;/P&gt;&lt;P&gt;applicable to secondary lists.&lt;/P&gt;&lt;P&gt;Top-of-page during line-selection.&lt;/P&gt;&lt;P&gt;At line-selection.&lt;/P&gt;&lt;P&gt;At user-command.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When you double click on any field in the basic list, you will be navigating to secondary list with detailed information pertaining to clicked field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As such we need to store the clicked field information at some variable. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;#145;Hide&amp;#146; temporarily stores the content of clicked field for later use.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The default title of the out put is the text what we enter during creation of program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This title can be changed using:&lt;/P&gt;&lt;P&gt;SET TITLEBAR &amp;#145;AAA&amp;#146;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;GUI status includes:&lt;/P&gt;&lt;P&gt;Menu bar&lt;/P&gt;&lt;P&gt;Application tool bar and&lt;/P&gt;&lt;P&gt;Activating standard tool bar&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;GUI status can be created using&lt;/P&gt;&lt;P&gt;SET PF-STATUS &amp;#145;BBB&amp;#146;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can have 8 menus ( out of which, 2 menus are reserved for &amp;#145;System&amp;#146; and &amp;#145;Help&amp;#146;).&lt;/P&gt;&lt;P&gt;Each menu can have 15 menu items.&lt;/P&gt;&lt;P&gt;Each menu item can have 3 levels of submenus.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can create 35 items in application tool bar.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example Code&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT zs_stockreport3&lt;/P&gt;&lt;P&gt;NO STANDARD PAGE HEADING&lt;/P&gt;&lt;P&gt;LINE-SIZE 255&lt;/P&gt;&lt;P&gt;MESSAGE-ID zz1.&lt;/P&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Table Declaration *&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;P&gt;TABLES: mara,&lt;/P&gt;&lt;P&gt;marc,&lt;/P&gt;&lt;P&gt;mard.&lt;/P&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Types Declaration *&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;P&gt;TYPES: BEGIN OF typ_mara,&lt;/P&gt;&lt;P&gt;matnr TYPE mara-matnr, "Material Number"&lt;/P&gt;&lt;P&gt;mbrsh TYPE mara-mbrsh, "Industrial Sector"&lt;/P&gt;&lt;P&gt;mtart TYPE mara-mtart, "Material Type"&lt;/P&gt;&lt;P&gt;meins TYPE mara-meins, "Base Unit of Measure"&lt;/P&gt;&lt;P&gt;END OF typ_mara.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TYPES: BEGIN OF typ_makt,&lt;/P&gt;&lt;P&gt;matnr TYPE makt-matnr, "Material Number"&lt;/P&gt;&lt;P&gt;maktx TYPE makt-maktx, "Material Description"&lt;/P&gt;&lt;P&gt;END OF typ_makt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TYPES: BEGIN OF typ_marc,&lt;/P&gt;&lt;P&gt;matnr TYPE marc-matnr, "Material Number"&lt;/P&gt;&lt;P&gt;werks TYPE marc-werks, "Plant Number"&lt;/P&gt;&lt;P&gt;END OF typ_marc.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TYPES: BEGIN OF typ_mard,&lt;/P&gt;&lt;P&gt;matnr TYPE marc-matnr, "Material Number"&lt;/P&gt;&lt;P&gt;werks TYPE marc-werks, "Plant Number"&lt;/P&gt;&lt;P&gt;lgort TYPE mard-lgort, "Storage Location"&lt;/P&gt;&lt;P&gt;END OF typ_mard.&lt;/P&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Intrnal tables Declaration *&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;P&gt;DATA: it_mara TYPE STANDARD TABLE OF typ_mara WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;DATA: it_makt TYPE STANDARD TABLE OF typ_makt WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;DATA: it_marc TYPE STANDARD TABLE OF typ_marc WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;DATA: it_mard TYPE STANDARD TABLE OF typ_mard WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Variable Declaration *&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;P&gt;DATA: v_count TYPE i.&lt;/P&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Selection Screen *&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN : BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.&lt;/P&gt;&lt;P&gt;SELECT-OPTIONS : s_matnr FOR mara-matnr.&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN : SKIP.&lt;/P&gt;&lt;P&gt;PARAMETERS : p_mtart LIKE mara-mtart.&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN : END OF BLOCK b1.&lt;/P&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Start Events *&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Initialization *&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;P&gt;INITIALIZATION.&lt;/P&gt;&lt;P&gt;***&lt;/P&gt;&lt;P&gt;PERFORM initial_input.&lt;/P&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;At Selection-screen *&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;P&gt;AT SELECTION-SCREEN.&lt;/P&gt;&lt;P&gt;***&lt;/P&gt;&lt;P&gt;PERFORM validte_inputdata.&lt;/P&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Start of Selection *&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;P&gt;START-OF-SELECTION.&lt;/P&gt;&lt;P&gt;***&lt;/P&gt;&lt;P&gt;SELECT matnr&lt;/P&gt;&lt;P&gt;mbrsh&lt;/P&gt;&lt;P&gt;mtart&lt;/P&gt;&lt;P&gt;meins&lt;/P&gt;&lt;P&gt;INTO TABLE it_mara&lt;/P&gt;&lt;P&gt;FROM mara&lt;/P&gt;&lt;P&gt;WHERE matnr IN s_matnr and&lt;/P&gt;&lt;P&gt;mtart = p_mtart.&lt;/P&gt;&lt;P&gt;if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;sort it_mara by matnr.&lt;/P&gt;&lt;P&gt;else.&lt;/P&gt;&lt;P&gt;MESSAGE e001 WITH 'No data Found' ' For the Given'&lt;/P&gt;&lt;P&gt;'Selection Criteria'(400).&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF NOT it_mara[] IS INITIAL.&lt;/P&gt;&lt;P&gt;SELECT matnr&lt;/P&gt;&lt;P&gt;maktx&lt;/P&gt;&lt;P&gt;INTO TABLE it_makt FROM makt&lt;/P&gt;&lt;P&gt;FOR ALL ENTRIES IN it_mara&lt;/P&gt;&lt;P&gt;WHERE matnr = it_mara-matnr&lt;/P&gt;&lt;P&gt;AND spras = sy-langu.&lt;/P&gt;&lt;P&gt;if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;sort it_makt by matnr.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF NOT it_mara[] IS INITIAL.&lt;/P&gt;&lt;P&gt;select matnr&lt;/P&gt;&lt;P&gt;werks&lt;/P&gt;&lt;P&gt;from marc&lt;/P&gt;&lt;P&gt;into table it_marc&lt;/P&gt;&lt;P&gt;for all entries in it_mara&lt;/P&gt;&lt;P&gt;where matnr = it_mara-matnr.&lt;/P&gt;&lt;P&gt;if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;sort it_marc by matnr werks.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF NOT it_marc[] IS INITIAL.&lt;/P&gt;&lt;P&gt;select matnr&lt;/P&gt;&lt;P&gt;werks&lt;/P&gt;&lt;P&gt;lgort&lt;/P&gt;&lt;P&gt;from mard&lt;/P&gt;&lt;P&gt;into table it_mard&lt;/P&gt;&lt;P&gt;for all entries in it_marc&lt;/P&gt;&lt;P&gt;where matnr = it_marc-matnr and&lt;/P&gt;&lt;P&gt;werks = it_marc-werks.&lt;/P&gt;&lt;P&gt;if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;sort it_mard by matnr werks lgort.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: a TYPE i.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at it_mara.&lt;/P&gt;&lt;P&gt;a = sy-tabix MOD 2.&lt;/P&gt;&lt;P&gt;IF a = 1.&lt;/P&gt;&lt;P&gt;FORMAT COLOR 5.&lt;/P&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;P&gt;FORMAT COLOR OFF.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;read table it_marc with key matnr = it_mara-matnr&lt;/P&gt;&lt;P&gt;binary search.&lt;/P&gt;&lt;P&gt;if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;read table it_mard with key matnr = it_marc-matnr&lt;/P&gt;&lt;P&gt;werks = it_marc-werks&lt;/P&gt;&lt;P&gt;binary search.&lt;/P&gt;&lt;P&gt;if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;read table it_makt with key matnr = it_mara-matnr&lt;/P&gt;&lt;P&gt;binary search.&lt;/P&gt;&lt;P&gt;if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;WRITE:/ sy-vline.&lt;/P&gt;&lt;P&gt;WRITE: 2 it_mara-matnr,&lt;/P&gt;&lt;P&gt;18 sy-vline, it_mara-mbrsh,&lt;/P&gt;&lt;P&gt;38 sy-vline, it_mara-mtart,&lt;/P&gt;&lt;P&gt;54 sy-vline, it_mara-meins,&lt;/P&gt;&lt;P&gt;78 sy-vline, it_makt-maktx,&lt;/P&gt;&lt;P&gt;120 sy-vline, it_marc-werks,&lt;/P&gt;&lt;P&gt;135 sy-vline, it_mard-lgort, 155 sy-vline.&lt;/P&gt;&lt;P&gt;clear : it_mara.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;clear : it_makt.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;WRITE: /(155) sy-uline.&lt;/P&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Top of Page *&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;P&gt;TOP-OF-PAGE.&lt;/P&gt;&lt;P&gt;***&lt;/P&gt;&lt;P&gt;FORMAT COLOR 1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;WRITE: /(155) sy-uline.&lt;/P&gt;&lt;P&gt;WRITE:/ sy-vline.&lt;/P&gt;&lt;P&gt;WRITE: 2 'Material Number',&lt;/P&gt;&lt;P&gt;18 sy-vline, 'Industrial Sector',&lt;/P&gt;&lt;P&gt;38 sy-vline, 'Material Type',&lt;/P&gt;&lt;P&gt;54 sy-vline, 'Base Unit of Measure',&lt;/P&gt;&lt;P&gt;78 sy-vline, 'Material Description',&lt;/P&gt;&lt;P&gt;120 sy-vline, 'Plant',&lt;/P&gt;&lt;P&gt;135 sy-vline, 'Storage Location',155 sy-vline.&lt;/P&gt;&lt;P&gt;WRITE: /(155) sy-uline.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORMAT RESET.&lt;/P&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;End of Page *&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;amp;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*&amp;amp; Form Initial_Input&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;amp;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Initailization of Select Option&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;STRONG&gt;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="-----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM initial_input .&lt;/P&gt;&lt;P&gt;CLEAR s_matnr.&lt;/P&gt;&lt;P&gt;REFRESH s_matnr.&lt;/P&gt;&lt;P&gt;s_matnr-low = '100-100'.&lt;/P&gt;&lt;P&gt;s_matnr-high = '111-111'.&lt;/P&gt;&lt;P&gt;s_matnr-sign = 'I'.&lt;/P&gt;&lt;P&gt;s_matnr-option = 'BT'.&lt;/P&gt;&lt;P&gt;APPEND s_matnr.&lt;/P&gt;&lt;P&gt;p_mtart = 'ROH'.&lt;/P&gt;&lt;P&gt;ENDFORM. " Initial_Input&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;amp;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*&amp;amp; Form Validte_Inputdta&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;amp;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Validation of Select Option&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;STRONG&gt;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="-----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM validte_inputdata .&lt;/P&gt;&lt;P&gt;SELECT SINGLE * FROM mara&lt;/P&gt;&lt;P&gt;WHERE matnr IN s_matnr.&lt;/P&gt;&lt;P&gt;IF sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;MESSAGE e001 WITH 'Material'(002) 'Type'(003) 'Does Not Exit'(400).&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;ENDFORM. " Validte_Inputdta&lt;/P&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;End of Selection *&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;vasu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Sep 2007 15:39:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833792#M663471</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-26T15:39:11Z</dc:date>
    </item>
    <item>
      <title>Re: REPORT EVENTS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833793#M663472</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi&lt;/P&gt;&lt;P&gt;good&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Event related to reports are not triggered based on any statements in ABAP.   &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The event are triggered depended on the way the output is generated .  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for eg: &lt;/P&gt;&lt;P&gt;Initialization : triggered when the report is loaded in memory. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;At selection-screen output : triggered when the selection screen is loaded in memory before being displayed. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;At selection-screen / &amp;lt;field&amp;gt; : before leaving the selection screen. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;start-of-selection : the first event for displaying the report. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;end-of-selection : after the start-of-selection is completed. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;classiscal report events. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;top-of-page : every time a new page is started in the list. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;end-of-page : every time the list data reaches the footer region of the page. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;interactive report events. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;top of page during line selection : top of page event for secondary list. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;at line-selection : evey time user dbl-clicks(F2) on the list data. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;at pF&amp;lt;key&amp;gt; : function key from F5 to F12 to perform interactive action on the list. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;&amp;lt;REMOVED BY MODERATOR&amp;gt;&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;P&gt;mrutyun^&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Alvaro Tejada Galindo&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Sep 2007 15:48:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833793#M663472</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-26T15:48:47Z</dc:date>
    </item>
    <item>
      <title>Re: REPORT EVENTS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833794#M663473</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi sekhar,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;          go through this documentation which clarifies your doubt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Order of Events:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Initialization&lt;/P&gt;&lt;P&gt;at selection screen&lt;/P&gt;&lt;P&gt;start of selection&lt;/P&gt;&lt;P&gt;top of page&lt;/P&gt;&lt;P&gt;end of page&lt;/P&gt;&lt;P&gt;end of selection...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;so initialization is used to pass default values to parameters &amp;amp; select-options&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;End of page is triggered when the content in the list reaches the no of lines specified....in case if it fails then use reserve n lines to explicitly trigger end of page...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Difference between Select-options &amp;amp; Ranges:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Select-options &amp;amp; ranges are basically internal tables...&lt;/P&gt;&lt;P&gt;however ranges have no selection screen whereas select-options do have.....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The main difference between them is in ranges the fields low &amp;amp; high are statically declared whereas in select-options we can dynamically specify the range of selection....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;please reward points if helpfull&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;with regards,&lt;/P&gt;&lt;P&gt;radhika kolluru.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 27 Sep 2007 05:35:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833794#M663473</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-27T05:35:59Z</dc:date>
    </item>
    <item>
      <title>Re: REPORT EVENTS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833795#M663474</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Events in reports&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Top-of-page&lt;/P&gt;&lt;P&gt;at selection-screen&lt;/P&gt;&lt;P&gt;start fo selection&lt;/P&gt;&lt;P&gt;at line selection&lt;/P&gt;&lt;P&gt;at user command&lt;/P&gt;&lt;P&gt;end of page &lt;/P&gt;&lt;P&gt;end of selection&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 27 Sep 2007 05:40:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833795#M663474</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-27T05:40:19Z</dc:date>
    </item>
    <item>
      <title>Re: REPORT EVENTS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833796#M663475</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reporting events occur in a predefined sequence and only in executable programs started using SUBMIT. In general, every executable program is implicitly started using SUBMIT. Only when a regular transaction code(Not Reporting-transactions )is used for the start or external calls of their subroutines, SUBMIT is not triggered. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When an executable program is linked with a logical database, the assigned subroutine is executed in the database program before a reporting event is triggered. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Executable programs are only directly executable from the end user's perspective. Whenever an executable program is started using System - Services - Reporting or a report transaction, the SUBMIT statement is executed. Executable programs are the only programs that can be called using SUBMIT. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;u&amp;gt;&amp;lt;b&amp;gt;Flow of an Executable Program&amp;lt;/b&amp;gt;&amp;lt;/u&amp;gt; &lt;/P&gt;&lt;P&gt;The SUBMIT statement loads the called program in a separate internal session and starts a series of processes in the ABAP runtime environment that trigger events and actions in the called program in the following order: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reporting event LOAD-OF-PROGRAM &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The start values defined using the DEFAULT addition in the statements PARAMETERS and SELECT-OPTIONS are passed to the relevant data objects. The start values of all other data objects are set before LOAD-OF-PROGRAM. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reporting event INITIALIZATION &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The selection screen specified in selscreen_options is called if it contains at least one input field or button. Complete selection screen processing is performed. Before the first event of the selection screen processing, AT SELECTION-SCREEN OUTPUT, the values specified in selscreen_options are passed. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reporting event START-OF-SELECTION &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Different GET events, if the called program is linked with a logical database. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reporting event END-OF-SELECTION &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The basic list is called. &lt;/P&gt;&lt;P&gt;If the basic list is empty, the program is exited.. &lt;/P&gt;&lt;P&gt;If the basic list is a print list, it is sent to the SAP spool system and the program is exited. &lt;/P&gt;&lt;P&gt;If EXPORTING LIST TO MEMORY is specified in list_options, the basic list is stored in the ABAP Memory and the program is exited. &lt;/P&gt;&lt;P&gt;Otherwise, the basic list is a screen list and is displayed on the screen. User actions on a displayed screen list trigger list events. The program is exited when the user exits the list display. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If no selection screen is displayed in step 4, because processing is performed in the background or not at all, the program flow is complete. &lt;/P&gt;&lt;P&gt;If a selection screen id displayed in step 4, the runtime environment calls the called program again after the basic list has been exited. During this new call, the runtime environment supplies the parameters, the selection criteria, and the free selections of the selection screen between the events INITIALIZATION and AT SELECTION-SCREEN OUTPUT with the previous input values. The program call is not complete until the user exits the selection screen processing by choosing Back, Exit, or Cancel. &lt;/P&gt;&lt;P&gt;The called program can be exited in any of these steps by using the LEAVE PROGRAM statement and during list processing by using LEAVE LIST-PROCESSING. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Notes&amp;lt;/b&amp;gt; &lt;/P&gt;&lt;P&gt;When the SUBMIT statement is executed, it is implicitly followed by an authorization check for the authorization group specified in the program attributes. &lt;/P&gt;&lt;P&gt;If the called program is linked with a logical database, the system calls the relevant subroutines of the database program for the steps listed above. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Bhaskar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 27 Sep 2007 05:44:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833796#M663475</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-27T05:44:18Z</dc:date>
    </item>
    <item>
      <title>Re: REPORT EVENTS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833797#M663476</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 27 Sep 2007 05:48:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833797#M663476</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-27T05:48:32Z</dc:date>
    </item>
    <item>
      <title>Re: REPORT EVENTS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833798#M663477</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sekhar,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The following events occur at runtime of a typical report program which uses logical databases:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;INITIALIZATION 					&lt;/P&gt;&lt;P&gt;Point before the selection screen is displayed&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When you start a program in which a selection screen is defined (either in the program itself or in the linked logical database program), the system normally processes this selection screen first. If you want to execute a processing block before the selection screen is processed, you can assign it to the event keyword INITIALIZATION. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AT SELECTION-SCREEN 				&lt;/P&gt;&lt;P&gt;Point after processing user input on the selection screen while the selection screen is still active.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;START-OF-SELECTION &lt;/P&gt;&lt;P&gt;The event START-OF-SELECTION gives you the possibility of creating a processing block after processing the selection screen and before accessing database tables using a logical database. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;GET &amp;lt;table&amp;gt;					&lt;/P&gt;&lt;P&gt;Point at which the logical database offers a line of the database table &amp;lt;table&amp;gt;. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;GET &amp;lt;table&amp;gt; LATE 				&lt;/P&gt;&lt;P&gt;Point after processing all tables which are hierarchically subordinate to the database table &amp;lt;table&amp;gt; in the structure  of the logical database.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;END-OF-SELECTION &lt;/P&gt;&lt;P&gt;To define a processing block after the system has read and processed all database tables of a logical database, use the keyword END-OF-SELECTION.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The following events occur during the processing of the output list of a report program:&lt;/P&gt;&lt;P&gt;TOP-OF-PAGE Point during list processing when a new page is started&lt;/P&gt;&lt;P&gt;END-OF-PAGE Point during list processing when a page is ended&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The following events occur during the display of the output list of a report program:&lt;/P&gt;&lt;P&gt;AT LINE-SELECTION	Point at which the user selects a line&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AT USER-COMMAND Point at which the user presses a function key or enters a command in the command field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AT PF&amp;lt;nn&amp;gt; Point at which the user presses the function key with the function code PF&amp;lt;n&amp;gt;.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 27 Sep 2007 05:59:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833798#M663477</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-27T05:59:13Z</dc:date>
    </item>
    <item>
      <title>Re: REPORT EVENTS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833799#M663478</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;First event -&lt;/P&gt;&lt;P&gt;Initialization : triggered when the report is loaded in memory.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;At selection-screen output : triggered when the selection screen is loaded in memory before being displayed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;At selection-screen : before leaving the selection screen.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;start-of-selection : the first event for displaying the report.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This event keyword defines an event block whose event is triggered by the ABAP runtime environment&lt;/P&gt;&lt;P&gt;when calling the executable program selection screen processing of a selection screen.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In an executable program, all statements that are not declarations,&lt;/P&gt;&lt;P&gt;and are listed before the first explicit processing block, are assigned to this event block.&lt;/P&gt;&lt;P&gt;If the program does not contain an explicitly defined event block START-OF-SELECTION,&lt;/P&gt;&lt;P&gt;these statements form the complete event block START-OF-SELECTION.&lt;/P&gt;&lt;P&gt;If a program contains an explicitly defined event block START-OF-SELECTION,&lt;/P&gt;&lt;P&gt;these statements are added to the beginning of the event block.&lt;/P&gt;&lt;P&gt;If the program contains no explicitly defined event blocks,&lt;/P&gt;&lt;P&gt;these statements form the entire event block START-OF-SELECTION.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;end-of-selection : after the start-of-selection is completed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;classiscal report events.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;top-of-page : every time a new page is started in the list.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;end-of-page : every time the list data reaches the footer region of the page.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;interactive report events.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;top of page during line selection : top of page event for secondary list.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;at line-selection : evey time user dbl-clicks(F2) on the list data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;at pF&amp;lt;key&amp;gt; : function key from F5 to F12 to perform interactive action on the list.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;at user-command&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please check the order of events at&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_47x200/helpdata/en/9f/db99fa35c111d1829f0000e829fbfe/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_47x200/helpdata/en/9f/db99fa35c111d1829f0000e829fbfe/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_47x200/helpdata/en/56/1eb6c705ad11d2952f0000e8353423/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_47x200/helpdata/en/56/1eb6c705ad11d2952f0000e8353423/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;c) list of interactive events&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_nw04/helpdata/en/9f/dba2eb35c111d1829f0000e829fbfe/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw04/helpdata/en/9f/dba2eb35c111d1829f0000e829fbfe/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;dilog programming events&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PBO event&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This event is triggered before the screen is displayed. The processing of screen before the display of screen is done in this event. For example, filling in default values in the screen fields.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PAI event&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This event is responsible for processing of screen after the user enters the data and clicks the pushbutton. The processing of screen can include displaying another screen, or just displaying list or quitting the transaction itself and many more things. Usually it is displaying another screen. These operations can be carried out in the PAI event. OKCODE plays an important role in this operation.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;POV event&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Process on value request is triggered when the user clicks F4 key. You can handle this event when the user presses F4 key by writing code for the same in module pool program. Normally when the user presses F4, list of possible values is displayed. The standard list produced by system is adequate for applications you develop yourself. However, you can also have the option of setting up your own documentation and lists of possible values that are more detailed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;POH event&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Normally when the user places the cursor on the field and presses F1 function key, the system displays its own Help for that particular field. You can add your own functionality to the Help button by writing code for the same in the POH event.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_webas630/helpdata/en/9f/db9cdc35c111d1829f0000e829fbfe/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_webas630/helpdata/en/9f/db9cdc35c111d1829f0000e829fbfe/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sapdevelopment.co.uk/dialog/dialoghome.htm" target="test_blank"&gt;http://www.sapdevelopment.co.uk/dialog/dialoghome.htm&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 27 Sep 2007 06:01:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/report-events/m-p/2833799#M663478</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-27T06:01:26Z</dc:date>
    </item>
  </channel>
</rss>

