<?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: ALV refresh display in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639466#M1443263</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;STRONG&gt;Refer this code in the user command of the ALV in the below wiki by me:-&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sdn.sap.com/irj/scn/wiki?path=/display/snippets/alv%252bgrid%252bdisplay%252bwith%252bcheckbox%252bto%252bprocess%252bselected%252brecords%252bat%252bruntime" target="test_blank"&gt;https://www.sdn.sap.com/irj/scn/wiki?path=/display/snippets/alv%252bgrid%252bdisplay%252bwith%252bcheckbox%252bto%252bprocess%252bselected%252brecords%252bat%252bruntime&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Tarun&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 22 Feb 2010 09:04:05 GMT</pubDate>
    <dc:creator>I355602</dc:creator>
    <dc:date>2010-02-22T09:04:05Z</dc:date>
    <item>
      <title>ALV refresh display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639462#M1443259</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi experts,&lt;/P&gt;&lt;P&gt;I put a refresh button onto the the ALV list. If it is pressed, I need to refresh the displaying of data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I found an Object Oriented solution but I need a fm to solve this problem and so far I did not found which fm could I use.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Feb 2010 08:21:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639462#M1443259</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-02-22T08:21:25Z</dc:date>
    </item>
    <item>
      <title>Re: ALV refresh display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639463#M1443260</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;Just submit the same program again with the same selection screen parameters and return. Means program will be executed again and data will be refreshed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ganga&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Feb 2010 08:42:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639463#M1443260</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-02-22T08:42:28Z</dc:date>
    </item>
    <item>
      <title>Re: ALV refresh display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639464#M1443261</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use Submit - call the same program with the same selection parameters - u ll get a refreshed output.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Feb 2010 08:55:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639464#M1443261</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-02-22T08:55:49Z</dc:date>
    </item>
    <item>
      <title>Re: ALV refresh display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639465#M1443262</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;On the User Command for the refresh Button click,&lt;/P&gt;&lt;P&gt;CHeck the sample code below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

*&amp;amp;---------------------------------------------------------------------*
*&amp;amp;      Form  USER_COMMAND
*&amp;amp;---------------------------------------------------------------------*
*       SUB-ROUTINE USER_COMMAND IS USED TO HANDLE THE USER ACTION
*       AND EXECUTE THE APPROPIATE CODE
*----------------------------------------------------------------------*
*      --&amp;gt;LV_OKCODE   used to capture the function code
*                     of the user-defined push-buttons
*      --&amp;gt;L_SELFIELD   text
*----------------------------------------------------------------------*
FORM user_command USING lv_okcode LIKE sy-ucomm l_selfield TYPE slis_selfield.

* assign the function code to variable v_okcode
  lv_okcode = sy-ucomm.

* handle the code execution based on the function code encountered
  CASE lv_okcode.

* when the function code is EXECUTE then process the selected records
    WHEN 'EXECUTE'.       "Here you can give func code of your refresh button

* refresh it_process when user processes selected records
      REFRESH it_process.

* to reflect the data changed into internal table
      DATA : ref_grid TYPE REF TO cl_gui_alv_grid. "new

      IF ref_grid IS INITIAL.
        CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'
          IMPORTING
            e_grid = ref_grid.
      ENDIF.

      IF NOT ref_grid IS INITIAL.
        CALL METHOD ref_grid-&amp;gt;check_changed_data.
      ENDIF.

*----------------------------------------------------------------------*
* sort the internal table by flag descending so that the selected
* records are appended at the beginning of internal table
*----------------------------------------------------------------------*
      SORT it_final BY flag DESCENDING.

*----------------------------------------------------------------------*
* move the selected records from final internal table into another
* internal table so that they can be processed
*----------------------------------------------------------------------*
      LOOP AT it_final INTO wa_final WHERE flag = 'X'.
        wa_process-aufnr = wa_final-aufnr.
        wa_process-ktext = wa_final-ktext.
        wa_process-qmnum = wa_final-qmnum.
        APPEND wa_process TO it_process.
      ENDLOOP.

* refresh the ALV Grid output from internal table
      l_selfield-refresh = c_check.

* now all the selected records by the user at run-time are appended into
* into a new internal table which can now be used to processed as per the
* user requirements
      DATA : line_count1 TYPE i.

      DESCRIBE TABLE it_process
      LINES line_count1.
      IF line_count1 GE 1.
        PERFORM user_action.
      ELSE.
        MESSAGE e002.
      ENDIF.

    WHEN 'SEL_ALL'.
* to select all the records displayed in ALV Grid
      LOOP AT it_final INTO wa_final.
        wa_final-flag = 'X'.
        MODIFY it_final FROM wa_final.
      ENDLOOP.
* refresh the ALV Grid output from internal table
      l_selfield-refresh = c_check.

    WHEN 'DESEL_ALL'.
* to deselect all the records displayed in ALV Grid
      LOOP AT it_final INTO wa_final.
        wa_final-flag = ' '.
        MODIFY it_final FROM wa_final.
      ENDLOOP.
* refresh the ALV Grid output from internal table
      l_selfield-refresh = c_check.

  ENDCASE.

ENDFORM.                    "USER_COMMAND

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it helps&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mansi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Feb 2010 09:03:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639465#M1443262</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-02-22T09:03:46Z</dc:date>
    </item>
    <item>
      <title>Re: ALV refresh display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639466#M1443263</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;STRONG&gt;Refer this code in the user command of the ALV in the below wiki by me:-&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sdn.sap.com/irj/scn/wiki?path=/display/snippets/alv%252bgrid%252bdisplay%252bwith%252bcheckbox%252bto%252bprocess%252bselected%252brecords%252bat%252bruntime" target="test_blank"&gt;https://www.sdn.sap.com/irj/scn/wiki?path=/display/snippets/alv%252bgrid%252bdisplay%252bwith%252bcheckbox%252bto%252bprocess%252bselected%252brecords%252bat%252bruntime&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Tarun&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Feb 2010 09:04:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639466#M1443263</guid>
      <dc:creator>I355602</dc:creator>
      <dc:date>2010-02-22T09:04:05Z</dc:date>
    </item>
    <item>
      <title>Re: ALV refresh display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639467#M1443264</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; Just Use the below FM  with CL_GUI_ALV_GRID  object .&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;CALL METHOD G_ALVGRID-&amp;gt;REFRESH_TABLE_DISPLAY     .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;Amit&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Feb 2010 09:13:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639467#M1443264</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-02-22T09:13:53Z</dc:date>
    </item>
    <item>
      <title>Re: ALV refresh display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639468#M1443265</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 the USER_COMMAND is Triggered,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;WHEN 'REFRESH'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;     p_selfield-refresh = 'X'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;use the above scenario you will get it 100% correct.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Prasad.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Feb 2010 09:20:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639468#M1443265</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-02-22T09:20:40Z</dc:date>
    </item>
    <item>
      <title>Re: ALV refresh display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639469#M1443266</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;selfield-refresh = 'X'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think maybe it could help. I have to perform the data selection before I set refresh to 'X'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Like this one:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;....&lt;/P&gt;&lt;P&gt;perform f_data_selection.&lt;/P&gt;&lt;P&gt;selfield-refresh = 'X'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: mrwhite on Feb 22, 2010 11:33 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Feb 2010 10:28:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639469#M1443266</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-02-22T10:28:53Z</dc:date>
    </item>
    <item>
      <title>Re: ALV refresh display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639470#M1443267</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Mansi I cannot read this code, sorry. It just copied without any formatting. I doesn't help at all, since I cannot read it.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Feb 2010 10:30:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639470#M1443267</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-02-22T10:30:09Z</dc:date>
    </item>
    <item>
      <title>Re: ALV refresh display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639471#M1443268</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Why don't you submit the same program again with the same selection screen parameters and return?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Ganga&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Feb 2010 10:37:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639471#M1443268</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-02-22T10:37:00Z</dc:date>
    </item>
    <item>
      <title>Re: ALV refresh display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639472#M1443269</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think selfield-refresh = 'X' is the most easiest way. I've already have the selection, all I need to do is just call the perform again.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks anyway, submit program could be an option as well.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Feb 2010 10:47:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639472#M1443269</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-02-22T10:47:25Z</dc:date>
    </item>
    <item>
      <title>Re: ALV refresh display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639473#M1443270</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Feb 2010 10:47:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639473#M1443270</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-02-22T10:47:41Z</dc:date>
    </item>
    <item>
      <title>Re: ALV refresh display</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639474#M1443271</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Prasad,&lt;/P&gt;&lt;P&gt;Really you solution helped me..Thanks a lot.....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Its a 100% solution for refreshing an ALV o/P Grid... &lt;SPAN __jive_emoticon_name="happy" __jive_macro_name="emoticon" class="jive_macro jive_emote" src="https://community.sap.com/1336/images/emoticons/happy.gif"&gt;&lt;/SPAN&gt; &lt;SPAN __jive_emoticon_name="happy" __jive_macro_name="emoticon" class="jive_macro jive_emote" src="https://community.sap.com/1336/images/emoticons/happy.gif"&gt;&lt;/SPAN&gt; &lt;SPAN __jive_emoticon_name="laugh" __jive_macro_name="emoticon" class="jive_macro_emoticon jive_macro jive_emote" src="https://community.sap.com/1336/images/emoticons/laugh.gif"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Sep 2015 07:20:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-refresh-display/m-p/6639474#M1443271</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2015-09-28T07:20:07Z</dc:date>
    </item>
  </channel>
</rss>

