<?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: At line selection event in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423979#M1244729</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;I am not displaying ALV when there is no data. But the field( Summary) is still displayed. &lt;/P&gt;&lt;P&gt;In this case, AT line selection event is triggering and and transaction is called successfully on Click.&lt;/P&gt;&lt;P&gt;The only issue is , when some data is displayed by ALV, then transaction is not called when clicking Summary field.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 03 Apr 2009 05:46:29 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-04-03T05:46:29Z</dc:date>
    <item>
      <title>At line selection event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423971#M1244721</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;My requirement is to display a filed and errors( in case any using ALV) in my report output. When user click on the filed, he should be prompted to a transaction. For this, I have put HOTSPOT on my field and wrriten code in AT line selection event.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;Now the issue is, When there is no ALV data ,  at line selection event triggers and user is prompted to  transaction screen. But when ALV data is displayed, HOTSPOT is not working for that field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kindly suggest.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Apr 2009 04:07:16 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423971#M1244721</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-03T04:07:16Z</dc:date>
    </item>
    <item>
      <title>Re: At line selection event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423972#M1244722</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;When an Interactive Report is needed in Classical Display, we go for AT LINE-SELECTION. But when the same is needed in ALV Display, this method won't work. Instead, we need to use other way which is explained below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We use REUSE_ALV_GRID_DISPLAY for ALV Display. Now, normally we call that FM in the following way:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'&lt;/P&gt;&lt;P&gt;       EXPORTING&lt;/P&gt;&lt;P&gt;            i_callback_program      = 'PROGRAM_NAME'&lt;/P&gt;&lt;P&gt;            it_fieldcat             = tb_fieldcat&lt;/P&gt;&lt;P&gt;       TABLES&lt;/P&gt;&lt;P&gt;            t_outtab                = tb_output.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;When it is needed to get an Interactive ALV, call the same FM in the following manner:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'&lt;/P&gt;&lt;P&gt;       EXPORTING&lt;/P&gt;&lt;P&gt;            i_callback_program      = 'ZTEST75599_1'&lt;/P&gt;&lt;P&gt;            it_fieldcat             = tb_fieldcat&lt;/P&gt;&lt;P&gt;            i_callback_user_command = 'USER_COMMAND'&lt;/P&gt;&lt;P&gt;       TABLES&lt;/P&gt;&lt;P&gt;            t_outtab                = tb_output.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now, in the report, create a subroutine with the name USER_COMMAND as follows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM user_command  USING p_ucomm    LIKE sy-ucomm&lt;/P&gt;&lt;P&gt;                         p_selfield TYPE slis_selfield.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CASE p_ucomm.&lt;/P&gt;&lt;P&gt;    WHEN '&amp;amp;IC1'.   " &amp;amp;IC1 - SAP standard code for double-clicking&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; Based on the requirement, write the logic                          *&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;  ENDCASE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFORM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;No need to call the subroutine as PERFORM user_command. This will be takane care by REUSE_ALV_GRID_DISPLAY. We need to just write the subroutine in the report. That suffices.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Some more useful points for Interactive ALV:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. If Hotspot is needed, then that should be done by declaring hotspot (one field in slis_t_fieldcat_alv) as 'X' in tb_fieldcat which is of type slis_t_fieldcat_alv. When hotspot is active, single click will be enough or else you should double click on the output data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. In Classical Display, when it is needed to read the record on which we double clicked, we do that in following way:&lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;   AT LINE-SELECTION.&lt;/P&gt;&lt;P&gt;       GET CURSOR LINE wf_line. " wf_line gives the line number on which it has been clicked&lt;/P&gt;&lt;P&gt;         READ LINE wf_line OF CURRENT PAGE. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  But this won't work for ALV. Instead, the following logic can be used:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM user_command  USING p_ucomm    LIKE sy-ucomm&lt;/P&gt;&lt;P&gt;                         p_selfield TYPE slis_selfield.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CASE p_ucomm.&lt;/P&gt;&lt;P&gt;    WHEN '&amp;amp;IC1'.   " &amp;amp;IC1 - SAP standard code for double-clicking&lt;/P&gt;&lt;P&gt;      READ TABLE tb_output INTO wa_output INDEX p_selfield-tabindex.&lt;/P&gt;&lt;P&gt;      IF sy-subrc EQ 0.&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; Based on the requirement, write the logic                          *&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;      ENDIF.&lt;/P&gt;&lt;P&gt;  ENDCASE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFORM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps you...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Apr 2009 04:09:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423972#M1244722</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-03T04:09:32Z</dc:date>
    </item>
    <item>
      <title>Re: At line selection event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423973#M1244723</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;I am using FM REUSE_ALV_BLOCK_LIST_DISPLAY  . In that FM there is no parameter like USER_COMMAND. And the filed on which I have put HOTSPOT , is not a part of ALV data. It is a independent filed which i have displayed using WRITE statement.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Apr 2009 04:17:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423973#M1244723</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-03T04:17:57Z</dc:date>
    </item>
    <item>
      <title>Re: At line selection event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423974#M1244724</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;You need to use the HIDE statment after the WRITE statement.&lt;/P&gt;&lt;P&gt;So that when you click on the value on the list then you can handle in the AT line selection event.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Refer to this link..for example [AT LINE -SELECTION|http://www.sapfans.com/sapfans/qstart/zhello7.html]&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Apr 2009 04:22:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423974#M1244724</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-03T04:22:45Z</dc:date>
    </item>
    <item>
      <title>Re: At line selection event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423975#M1244725</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rajneesh,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If u r using normal write statement u should use &lt;STRONG&gt;HIDE&lt;/STRONG&gt; statement for the particluar fields&lt;/P&gt;&lt;P&gt;which satisfies the conditions.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for eq:  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;WRITE: /1 WA_EBAN-WERKS,
                WA_EBAN-MATNR,
                WA_EBAN-BEDNR HOTSPOT.
    HIDE: WA_EBAN-MATNR
    HIDE: WA_EBAN-BEDNR.
    HIDE: WA_EBAN-WERKS.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;AT LINE-SELECTION.
  DATA NO TYPE I.
  DATA F(16).
  DATA G(16).
  CASE SY-LSIND.
    WHEN 1.
      GET CURSOR FIELD F.
      IF F EQ 'WA_EBAN-BEDNR'.
        PERFORM DRILL_DOWN.
      ENDIF.
  ENDCASE.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &lt;/P&gt;&lt;P&gt;Karthik&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Apr 2009 04:40:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423975#M1244725</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-03T04:40:52Z</dc:date>
    </item>
    <item>
      <title>Re: At line selection event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423976#M1244726</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;try to fm REUSE_ALV_BLOCK_LIST_APPEND&lt;/P&gt;&lt;P&gt;there will be a table called IT_EVENT in the function module&lt;/P&gt;&lt;P&gt;pass event name and form name and append the table  and pass table &lt;/P&gt;&lt;P&gt;to function module.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;R K.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: R K on Apr 3, 2009 10:45 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Apr 2009 05:09:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423976#M1244726</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-03T05:09:08Z</dc:date>
    </item>
    <item>
      <title>Re: At line selection event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423977#M1244727</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;I have shown a filed let say 'Summary' and then below that my ALV data. Now I want if a user click on Summary , A transaction should be called. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have tried HIDE also. Its  working only when no ALV data is displayed.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Apr 2009 05:14:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423977#M1244727</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-03T05:14:29Z</dc:date>
    </item>
    <item>
      <title>Re: At line selection event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423978#M1244728</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;   I need a small clarification, &lt;/P&gt;&lt;P&gt;  when there is no Data, then why are you displaying the ALV...?&lt;/P&gt;&lt;P&gt;Could you please let me know....?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Vamsi.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Apr 2009 05:42:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423978#M1244728</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-03T05:42:31Z</dc:date>
    </item>
    <item>
      <title>Re: At line selection event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423979#M1244729</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;I am not displaying ALV when there is no data. But the field( Summary) is still displayed. &lt;/P&gt;&lt;P&gt;In this case, AT line selection event is triggering and and transaction is called successfully on Click.&lt;/P&gt;&lt;P&gt;The only issue is , when some data is displayed by ALV, then transaction is not called when clicking Summary field.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Apr 2009 05:46:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423979#M1244729</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-03T05:46:29Z</dc:date>
    </item>
    <item>
      <title>Re: At line selection event</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423980#M1244730</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;In the AT line selection event write a condition....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AT LINE-SELECTION.&lt;/P&gt;&lt;P&gt;if table is not initial.&lt;/P&gt;&lt;P&gt;"  processing steps....&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Siddarth&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Apr 2009 05:49:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/at-line-selection-event/m-p/5423980#M1244730</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-03T05:49:32Z</dc:date>
    </item>
  </channel>
</rss>

