<?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: event in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433385#M544089</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;&amp;lt;b&amp;gt;Events&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Objects or classes can use events to trigger event handler methods in other objects or classes. In a normal method call, one method can be called by any number of users. When an event is triggered, any number of event handler methods can be called. The link between the trigger and the handler is not established until runtime. In a normal method call, the calling program determines the methods that it wants to call. These methods must exist. With events, the handler determines the events to which it wants to react. There does not have to be a handler method registered for every event. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The events of a class can be triggered in the methods of the same class using the RAISE EVENT statement. You can declare a method of the same or a different class as an event handler method for the event &amp;lt;evt&amp;gt; of class &amp;lt;class&amp;gt; using the addition FOR EVENT &amp;lt;evt&amp;gt; OF &amp;lt;class&amp;gt;. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Events have a similar parameter interface to methods, but only have output parameters. These parameters are passed by the trigger (RAISE EVENT statement) to the event handler method, which receives them as input parameters.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The link between trigger and handler is established dynamically in a program using the SET HANDLER statement. The trigger and handlers can be objects or classes, depending on whether you have instance or static events and event handler methods. When an event is triggered, the corresponding event handler methods are executed in all registered handling classes.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Instance Events&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You declare instance events using the EVENTS statement. An instance event can only be triggered in an instance method. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Static Events&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You declare static events using the CLASS-EVENTS statement. All methods (instance and static methods) can trigger static events. Static events are the only type of event that can be triggered in a static method. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Events Examples:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;RIGHT_CLICK             &lt;/P&gt;&lt;P&gt;TOOLBAR_MENUBUTTON_CLICK&lt;/P&gt;&lt;P&gt;CLICK_COL_HEADER         &lt;/P&gt;&lt;P&gt;DBLCLICK_ROW_COL        &lt;/P&gt;&lt;P&gt;CLICK_ROW_COL           &lt;/P&gt;&lt;P&gt;TOOLBAR_BUTTON_CLICK  &lt;/P&gt;&lt;P&gt;DOUBLE_CLICK_COL_SEPARAT&lt;/P&gt;&lt;P&gt;DELAYED_CHANGE_SELECTION&lt;/P&gt;&lt;P&gt;CONTEXT_MENU            &lt;/P&gt;&lt;P&gt;TOTAL_CLICK_ROW_COL &lt;/P&gt;&lt;P&gt;CONTEXT_MENU_SELECTED   &lt;/P&gt;&lt;P&gt;DOUBLE_CLICK&lt;/P&gt;&lt;P&gt;PRINT_TOP_OF_PAGE&lt;/P&gt;&lt;P&gt;PRINT_TOP_OF_LIST&lt;/P&gt;&lt;P&gt;PRINT_END_OF_PAGE&lt;/P&gt;&lt;P&gt;PRINT_END_OF_LIST&lt;/P&gt;&lt;P&gt;TOP_OF_PAGE&lt;/P&gt;&lt;P&gt;MENU_BUTTON&lt;/P&gt;&lt;P&gt;TOOLBAR&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Azaz Ali.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 20 Jun 2007 08:39:48 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-06-20T08:39:48Z</dc:date>
    <item>
      <title>event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433383#M544087</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;what is the exact definnition of an event&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Jun 2007 06:57:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433383#M544087</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-06-20T06:57:23Z</dc:date>
    </item>
    <item>
      <title>Re: event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433384#M544088</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;look at the below link&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_nw04/helpdata/en/71/a8a77955bc11d194aa0000e8353423/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw04/helpdata/en/71/a8a77955bc11d194aa0000e8353423/content.htm&lt;/A&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;Regards&lt;/P&gt;&lt;P&gt; Sudheer&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Jun 2007 07:06:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433384#M544088</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-06-20T07:06:43Z</dc:date>
    </item>
    <item>
      <title>Re: event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433385#M544089</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;&amp;lt;b&amp;gt;Events&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Objects or classes can use events to trigger event handler methods in other objects or classes. In a normal method call, one method can be called by any number of users. When an event is triggered, any number of event handler methods can be called. The link between the trigger and the handler is not established until runtime. In a normal method call, the calling program determines the methods that it wants to call. These methods must exist. With events, the handler determines the events to which it wants to react. There does not have to be a handler method registered for every event. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The events of a class can be triggered in the methods of the same class using the RAISE EVENT statement. You can declare a method of the same or a different class as an event handler method for the event &amp;lt;evt&amp;gt; of class &amp;lt;class&amp;gt; using the addition FOR EVENT &amp;lt;evt&amp;gt; OF &amp;lt;class&amp;gt;. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Events have a similar parameter interface to methods, but only have output parameters. These parameters are passed by the trigger (RAISE EVENT statement) to the event handler method, which receives them as input parameters.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The link between trigger and handler is established dynamically in a program using the SET HANDLER statement. The trigger and handlers can be objects or classes, depending on whether you have instance or static events and event handler methods. When an event is triggered, the corresponding event handler methods are executed in all registered handling classes.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Instance Events&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You declare instance events using the EVENTS statement. An instance event can only be triggered in an instance method. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Static Events&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You declare static events using the CLASS-EVENTS statement. All methods (instance and static methods) can trigger static events. Static events are the only type of event that can be triggered in a static method. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Events Examples:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;RIGHT_CLICK             &lt;/P&gt;&lt;P&gt;TOOLBAR_MENUBUTTON_CLICK&lt;/P&gt;&lt;P&gt;CLICK_COL_HEADER         &lt;/P&gt;&lt;P&gt;DBLCLICK_ROW_COL        &lt;/P&gt;&lt;P&gt;CLICK_ROW_COL           &lt;/P&gt;&lt;P&gt;TOOLBAR_BUTTON_CLICK  &lt;/P&gt;&lt;P&gt;DOUBLE_CLICK_COL_SEPARAT&lt;/P&gt;&lt;P&gt;DELAYED_CHANGE_SELECTION&lt;/P&gt;&lt;P&gt;CONTEXT_MENU            &lt;/P&gt;&lt;P&gt;TOTAL_CLICK_ROW_COL &lt;/P&gt;&lt;P&gt;CONTEXT_MENU_SELECTED   &lt;/P&gt;&lt;P&gt;DOUBLE_CLICK&lt;/P&gt;&lt;P&gt;PRINT_TOP_OF_PAGE&lt;/P&gt;&lt;P&gt;PRINT_TOP_OF_LIST&lt;/P&gt;&lt;P&gt;PRINT_END_OF_PAGE&lt;/P&gt;&lt;P&gt;PRINT_END_OF_LIST&lt;/P&gt;&lt;P&gt;TOP_OF_PAGE&lt;/P&gt;&lt;P&gt;MENU_BUTTON&lt;/P&gt;&lt;P&gt;TOOLBAR&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Azaz Ali.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Jun 2007 08:39:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433385#M544089</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-06-20T08:39:48Z</dc:date>
    </item>
    <item>
      <title>Re: event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433386#M544090</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;Check out the link&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_nw2004s/helpdata/en/c3/225b5c54f411d194a60000e8353423/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw2004s/helpdata/en/c3/225b5c54f411d194a60000e8353423/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It gives a detailed description of events. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In general terms, event is a specific operation that happens.&lt;/P&gt;&lt;P&gt;Example can be a button click, a radiobutton selection, a sales order creation, a leave request creation.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Some specific operation needs to be done on this event. Event handler method recognize the event and start the operation. &lt;/P&gt;&lt;P&gt;Like on a button click i want to display some specific data.&lt;/P&gt;&lt;P&gt;Then button click is the event, An event handler method recognize this button click and call a form which gets the data from database and displays it in the form of some list.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Other links are&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_nw2004s/helpdata/en/41/7af4eca79e11d1950f0000e82de14a/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw2004s/helpdata/en/41/7af4eca79e11d1950f0000e82de14a/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this explanation helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Richa&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Jun 2007 08:48:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433386#M544090</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-06-20T08:48:52Z</dc:date>
    </item>
    <item>
      <title>Re: event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433387#M544091</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sandeep,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Event is basically one of the components of a class. An event can be raised at certain points of program execution either by system or explicitly by the programmer. Whenever an event is raised control will flow to the handler methos defined and registered for the event. So the programmer can specify in the code the actions to be carried out when an event is raised, in the event hadler method.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check the following program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLASS lcl_vehicle DEFINITION DEFERRED.&lt;/P&gt;&lt;P&gt;DATA: vehicle_list TYPE TABLE OF REF TO lcl_vehicle,&lt;/P&gt;&lt;P&gt;         r_vehicles TYPE REF TO lcl_vehicle.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;----&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;      CLASS lcl_vehicle DEFINITION&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;*&lt;/P&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;CLASS lcl_vehicle DEFINITION.&lt;/P&gt;&lt;P&gt;  PUBLIC SECTION.&lt;/P&gt;&lt;P&gt;    EVENTS: vehicle_created.&lt;/P&gt;&lt;P&gt;    METHODS: set IMPORTING im_make TYPE string&lt;/P&gt;&lt;P&gt;                           im_year TYPE i,&lt;/P&gt;&lt;P&gt;             add_vehicle FOR EVENT vehicle_created OF lcl_vehicle&lt;/P&gt;&lt;P&gt;                           IMPORTING sender,&lt;/P&gt;&lt;P&gt;             display_attributes.&lt;/P&gt;&lt;P&gt;    CLASS-DATA:n_o_vehicles TYPE i.&lt;/P&gt;&lt;P&gt;  PRIVATE SECTION.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    DATA:       make TYPE string, year TYPE i.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;   CLASS-DATA:n_o_vehicles TYPE i.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;ENDCLASS.                    "lcl_vehicle DEFINITION&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;----&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;      CLASS lcl_vehicle IMPLEMENTATION&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;*&lt;/P&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;CLASS lcl_vehicle IMPLEMENTATION.&lt;/P&gt;&lt;P&gt;  METHOD set.&lt;/P&gt;&lt;P&gt;    make = im_make.&lt;/P&gt;&lt;P&gt;    year = im_year.&lt;/P&gt;&lt;P&gt;    n_o_vehicles = n_o_vehicles + 1.&lt;/P&gt;&lt;P&gt;    RAISE EVENT vehicle_created.&lt;/P&gt;&lt;P&gt;  ENDMETHOD.                    "write:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  METHOD add_vehicle.&lt;/P&gt;&lt;P&gt;    APPEND sender TO vehicle_list.&lt;/P&gt;&lt;P&gt;  ENDMETHOD.                    "add_vehicle&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  METHOD display_attributes.&lt;/P&gt;&lt;P&gt;    WRITE: make, year.&lt;/P&gt;&lt;P&gt;  ENDMETHOD.                    "display_attributes&lt;/P&gt;&lt;P&gt;ENDCLASS.                    "lcl_vehicle IMPLEMENTATION&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA r_vehicle TYPE REF TO lcl_vehicle.&lt;/P&gt;&lt;P&gt;DATA r_vehicle1 TYPE REF TO lcl_vehicle.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;START-OF-SELECTION.&lt;/P&gt;&lt;P&gt;  CREATE OBJECT r_vehicle .&lt;/P&gt;&lt;P&gt;  CREATE OBJECT r_vehicle1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  SET HANDLER r_vehicle1-&amp;gt;add_vehicle FOR ALL INSTANCES.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;      FOR r_vehicle1.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; SET HANDLER r_vehicle1-&amp;gt;add_vehicle FOR r_vehicle1.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  CALL METHOD r_vehicle-&amp;gt;set&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      im_make = 'Hyundai'&lt;/P&gt;&lt;P&gt;      im_year = 2001.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL METHOD r_vehicle1-&amp;gt;set&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      im_make = 'Benz'&lt;/P&gt;&lt;P&gt;      im_year = 2000.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  LOOP AT vehicle_list INTO r_vehicles.&lt;/P&gt;&lt;P&gt;    CALL METHOD r_vehicles-&amp;gt;display_attributes.&lt;/P&gt;&lt;P&gt;  ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are many applications of this. Suppose you are displaying a list output through ALV and requirement is whenever user double clicks on a line in ALV output, a message is to be displayed. For implementing this you can use the predefined event "double_click" in the ALV class &amp;lt;b&amp;gt;cl_gui_alv_grid&amp;lt;/b&amp;gt;. In your program define a event handler method (in a local class) for this event and register the method for this event using SET HANDLER statement. Noew in the event handler method you can put in the code for displaying the message.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check out the following link for more info on events. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_47x200/helpdata/en/c9/5472fc787f11d194c90000e8353423/frameset.htm" target="test_blank"&gt;http://help.sap.com/saphelp_47x200/helpdata/en/c9/5472fc787f11d194c90000e8353423/frameset.htm&lt;/A&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Award points if found useful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Indrajit.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Jun 2007 08:50:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433387#M544091</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-06-20T08:50:48Z</dc:date>
    </item>
    <item>
      <title>Re: event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433388#M544092</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;Look at the Below link&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sdn.sap.com/irj/sdn/wiki?path=/display/abap/object" target="test_blank"&gt;https://www.sdn.sap.com/irj/sdn/wiki?path=/display/abap/object&lt;/A&gt;&lt;EM&gt;Oriented&lt;/EM&gt;ABAP+(OO-ABAP)&amp;amp;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_nw04/helpdata/en/c4/3a7f12505211d189550000e829fbbd/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw04/helpdata/en/c4/3a7f12505211d189550000e829fbbd/content.htm&lt;/A&gt; &lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_nw04/helpdata/en/c4/3a7f12505211d189550000e829fbbd/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw04/helpdata/en/c4/3a7f12505211d189550000e829fbbd/content.htm&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Jun 2007 04:00:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433388#M544092</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-06-21T04:00:58Z</dc:date>
    </item>
    <item>
      <title>Re: event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433389#M544093</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;    Methods: handler_e1 handles event e1&lt;/P&gt;&lt;P&gt;handles events&lt;/P&gt;&lt;P&gt;e1 and e2&lt;/P&gt;&lt;P&gt;Publish and Subscribe&lt;/P&gt;&lt;P&gt;  The ABAP Objects event concept provides a loose association between objects, where&lt;/P&gt;&lt;P&gt;&amp;#150; The class (static event) or object (instance event) raising the event does not know who will respond&lt;/P&gt;&lt;P&gt;&amp;#150; Potential responding classes or objects can decide for themselves whether to respond&lt;/P&gt;&lt;P&gt;  ABAP Object events use the publish and subscribe approach: (1) A class declares an event and&lt;/P&gt;&lt;P&gt;implements a method to raise (publish) the event; (2) The same and/or other classes implement a&lt;/P&gt;&lt;P&gt;method to respond (subscribe) to the event; (3) At runtime, interested classes and objects register their wish and availability to respond.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Events &amp;#150; Defining and Triggering&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
CLASS C1 DEFINITION.
PUBLIC SECTION.
METHODS trigger_event.
EVENTS e1 EXPORTING &amp;#133;
VALUE(e1) &amp;#133;
CLASS-EVENTS:
PROTECTED SECTION.
PRIVATE SECTION.
ENDCLASS.
CLASS C1 IMPLEMENTATION.
METHOD trigger_event.
RAISE EVENT e1 EXPORTING &amp;#133;
ENDMETHOD.
ENDCLASS.
&amp;#133;
INTERFACE i1.
METHODS trigger_event.
EVENTS e1 EXPORTING &amp;#133;
VALUE(e1) &amp;#133;
ENDINTERFACE.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;  Events can be declared as PUBLIC,&lt;/P&gt;&lt;P&gt;PROTECTED, or PRIVATE components of any&lt;/P&gt;&lt;P&gt;class or interface&lt;/P&gt;&lt;P&gt;  There can be both instance and static events&lt;/P&gt;&lt;P&gt;  The parameter interface for events is limited to&lt;/P&gt;&lt;P&gt;EXPORTING parameters, passed by VALUE&lt;/P&gt;&lt;P&gt;  Events can be triggered by any method in the&lt;/P&gt;&lt;P&gt;class, using the RAISE EVENT statement&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Events &amp;#150; Handling&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
CLASS C2 DEFINITION.
PUBLIC SECTION.
METHODS event_handler FOR EVENT
e1 OF c1
IMPORTING e1.
ENDCLASS.
CLASS C2 IMPLEMENTATION.
METHOD event_handler.
&amp;#133;
ENDMETHOD.
ENDCLASS.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;  Any class can define event handler methods for&lt;/P&gt;&lt;P&gt;the events of the class itself or for those of other&lt;/P&gt;&lt;P&gt;classes&lt;/P&gt;&lt;P&gt;  Event handler methods use the FOR EVENT e1&lt;/P&gt;&lt;P&gt;OF {class | interface} addition&lt;/P&gt;&lt;P&gt;  The event handler&amp;#146;s parameter interface is limited&lt;/P&gt;&lt;P&gt;to importing those parameters defined in the&lt;/P&gt;&lt;P&gt;event declaration&lt;/P&gt;&lt;P&gt;&amp;#150; The import parameters are not typed but adopt the&lt;/P&gt;&lt;P&gt;typing of the raised event&amp;#146;s exporting parameters &amp;#150;&lt;/P&gt;&lt;P&gt;the interface is fully defined in the event declaration,&lt;/P&gt;&lt;P&gt;which helps make the trigger completely independent&lt;/P&gt;&lt;P&gt;of any potential handlers&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward if u find helpful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;rajesh&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Jun 2007 06:00:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/event/m-p/2433389#M544093</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-06-21T06:00:41Z</dc:date>
    </item>
  </channel>
</rss>

