<?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: Push Button On ALV in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/push-button-on-alv/m-p/3357665#M805663</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Chadru..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 01 Feb 2008 12:17:53 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-02-01T12:17:53Z</dc:date>
    <item>
      <title>Push Button On ALV</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/push-button-on-alv/m-p/3357661#M805659</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have done coding for G/L interface . This report displays an ALV at the end after performnig validations on each record uploaded from a flat file. Once all records are checked , the ALV requires a PUSH BUTTON that when triggered will post the records.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  My query is, how shud i add a push button in the ALV in the title bar.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Feb 2008 10:50:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/push-button-on-alv/m-p/3357661#M805659</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-01T10:50:08Z</dc:date>
    </item>
    <item>
      <title>Re: Push Button On ALV</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/push-button-on-alv/m-p/3357662#M805660</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;You have to copy the standard pf status to a new one.&lt;/P&gt;&lt;P&gt;For this go to the ALV screen and take the menu System -&amp;gt; Status. (I do not access to the system now) then look for the standard pf status. Copy this to Z range and then add your new button.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Even you can do in this method&lt;/P&gt;&lt;P&gt;Create a GUI status.&lt;/P&gt;&lt;P&gt;Go to GUI Status-&amp;gt;Application toolbar.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;THen add the button by giving &lt;/P&gt;&lt;P&gt;Function text&lt;/P&gt;&lt;P&gt;Icon name &lt;/P&gt;&lt;P&gt;Icon text &lt;/P&gt;&lt;P&gt;Info. text &lt;/P&gt;&lt;P&gt;Fastpath &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then in PBO of the screen,&lt;/P&gt;&lt;P&gt;Just give in a module&lt;/P&gt;&lt;P&gt;set pf_status 'ZSTATUS'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is an example for your question&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
TYPE-POOLS: slis.

DATA: i_qmel LIKE qmel OCCURS 0.
data v_repid type repid.
SELECT * FROM qmel INTO TABLE i_qmel.

v_repid = sy-repid.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_CALLBACK_PROGRAM = v_repid
I_CALLBACK_PF_STATUS_SET = 'SET_PF_STATUS'
I_CALLBACK_USER_COMMAND = 'USER_COMMAND'
i_structure_name = 'QMEL'
TABLES
t_outtab = i_qmel
EXCEPTIONS
program_error = 1
OTHERS = 2.
IF sy-subrc 0.

MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO 
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4. 
ENDIF.

form set_pf_status using rt_extab type slis_t_extab.
set pf-status 'TEST'.
endform.

FORM user_command USING ucomm LIKE sy-ucomm
selfield TYPE slis_selfield.
data lv_ucomm type sy-ucomm.
lv_ucomm 
= sy-ucomm. 
CASE lv_ucomm.
WHEN 'BUTTON'. "Double Click line Item
call transaction 'MM01'.
endcase.
endform.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To Click on the you have to do in the following way&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
i_callback_user_command = 'USER_COMMAND'

form user_command using i_ucomm like sy-ucomm 
is_selfield type slis_selfield.

case i_ucomm. 

when 'XXXX'. "XXXX is the function code for new button
endcase.
endform.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For More info please refer the below links&lt;/P&gt;&lt;P&gt;Please refer the following&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sdn.sap.com/sdn/collaboration.sdn?contenttype=url&amp;amp;content=https%3A//forums.sdn.sap.com/thread.jspa%3FthreadID%3D38170%26messageID%3D368851" target="test_blank"&gt;https://www.sdn.sap.com/sdn/collaboration.sdn?contenttype=url&amp;amp;content=https%3A//forums.sdn.sap.com/thread.jspa%3FthreadID%3D38170%26messageID%3D368851&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sap-basis-abap.com/abap/add-button-to-alv-toolbar-with-reuse-alv-list-display.htm" target="test_blank"&gt;http://www.sap-basis-abap.com/abap/add-button-to-alv-toolbar-with-reuse-alv-list-display.htm&lt;/A&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;Chandru&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Feb 2008 10:54:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/push-button-on-alv/m-p/3357662#M805660</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-01T10:54:58Z</dc:date>
    </item>
    <item>
      <title>Re: Push Button On ALV</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/push-button-on-alv/m-p/3357663#M805661</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;Please refer to the link below :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sapdev.co.uk/reporting/alv/alvgrid_pfstatus.htm" target="test_blank"&gt;http://www.sapdev.co.uk/reporting/alv/alvgrid_pfstatus.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sriram Ponna.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Feb 2008 10:58:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/push-button-on-alv/m-p/3357663#M805661</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-01T10:58:35Z</dc:date>
    </item>
    <item>
      <title>Re: Push Button On ALV</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/push-button-on-alv/m-p/3357664#M805662</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, &lt;/P&gt;&lt;P&gt;Create a new pf-status. In that copy the required icons from standard pf-status. Add the button you require for the report.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Add this functionality to the program :&lt;/P&gt;&lt;P&gt;set pf-status 'newpf'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;case sy-ucomm. &lt;/P&gt;&lt;P&gt;   when 'button'.&lt;/P&gt;&lt;P&gt;   perform &amp;lt; action &amp;gt;.&lt;/P&gt;&lt;P&gt;endcase.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reward if helpful.&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;cs.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Feb 2008 11:09:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/push-button-on-alv/m-p/3357664#M805662</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-01T11:09:55Z</dc:date>
    </item>
    <item>
      <title>Re: Push Button On ALV</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/push-button-on-alv/m-p/3357665#M805663</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Chadru..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Feb 2008 12:17:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/push-button-on-alv/m-p/3357665#M805663</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-01T12:17:53Z</dc:date>
    </item>
    <item>
      <title>Re: Push Button On ALV</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/push-button-on-alv/m-p/3357666#M805664</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Have a look at demo report BCALV_GRID_05, it is the most elegant solution.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Bert&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Feb 2008 14:21:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/push-button-on-alv/m-p/3357666#M805664</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-01T14:21:38Z</dc:date>
    </item>
  </channel>
</rss>

