<?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 Report in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-report/m-p/3581296#M862162</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 ALV, to refresh the table you have to call the method "refresh_table_display".  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It has the syntax very similar to creating the table.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It has two parameters. In the first one, you can mention if you want to refresh only the data (the icons are not refreshed)  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if you want to refresh only the icons around the grid (the data is not refreshed - this option is mostly not used in day to day applications). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the synatx is :- &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call method grid (name of grid )-&amp;gt;refresh_table_display &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;exporting &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IS_STABLE = &amp;lt;STRUCT OF TYPE LVC_S_STBL&amp;gt; (THIS IS FOR DATA REFRESHING) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I_SOFT_REFRESH = &amp;lt;VARIABLE OF CHAR 01&amp;gt;  (THIS IS FOR ICON REFRESHING). &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>Tue, 18 Mar 2008 11:04:23 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-03-18T11:04:23Z</dc:date>
    <item>
      <title>ALV Report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-report/m-p/3581291#M862157</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello All,&lt;/P&gt;&lt;P&gt;         what is the Function Module to refresh the data&lt;/P&gt;&lt;P&gt;          displayed in ALV Grid Display.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Mar 2008 10:09:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-report/m-p/3581291#M862157</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-18T10:09:17Z</dc:date>
    </item>
    <item>
      <title>Re: ALV Report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-report/m-p/3581292#M862158</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;what u want to do exactly?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Mar 2008 10:12:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-report/m-p/3581292#M862158</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-18T10:12:34Z</dc:date>
    </item>
    <item>
      <title>Re: ALV Report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-report/m-p/3581293#M862159</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 this link&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.jt77.com/development1/programming-23891.html" target="test_blank"&gt;http://www.jt77.com/development1/programming-23891.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;rgds,&lt;/P&gt;&lt;P&gt;bharat.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Mar 2008 10:17:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-report/m-p/3581293#M862159</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-18T10:17:14Z</dc:date>
    </item>
    <item>
      <title>Re: ALV Report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-report/m-p/3581294#M862160</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;PRE&gt;&lt;CODE&gt;

REPORT z_demo_alv_refresh_button.
**********************************************************************
* REPORT Z_DEMO_ALV_REFRESH_BUTTON - ALV Grid with refresh button    *
*--------------------------------------------------------------------*
* 
**********************************************************************
CONSTANTS :
  c_x VALUE 'X'.
*---------------------------------------------------------------------*
TYPE-POOLS: slis.                      " ALV Global Types

CONSTANTS :
  gc_refresh TYPE syucomm VALUE '&amp;amp;REFRESH'.

TYPES:
  BEGIN OF ty_mara,
    ernam TYPE mara-ernam,
    matnr TYPE mara-matnr,
    ersda TYPE mara-ersda,
    brgew TYPE mara-brgew,
  END OF ty_mara.

DATA:
  gt_mara TYPE TABLE OF ty_mara.

*---------------------------------------------------------------------*
START-OF-SELECTION.

  PERFORM f_read_data.

*---------------------------------------------------------------------*
END-OF-SELECTION.

  PERFORM f_display_data.

*---------------------------------------------------------------------*
*       Form  f_read_data
*---------------------------------------------------------------------*
FORM f_read_data.

  STATICS :
    l_rows TYPE i.

  ADD 1 TO l_rows.
  SELECT ernam matnr ersda brgew INTO TABLE gt_mara FROM mara
                                   UP TO l_rows ROWS.

  MESSAGE s208(00) WITH 'Reading data ...'.

ENDFORM.                               " F_READ_DATA
*---------------------------------------------------------------------*
*      Form  f_display_data
*---------------------------------------------------------------------*
FORM f_display_data.

  DEFINE m_fieldcat.
    add 1 to ls_fieldcat-col_pos.
    ls_fieldcat-fieldname = &amp;amp;1.
    ls_fieldcat-ref_tabname = 'MARA'.
    append ls_fieldcat to lt_fieldcat.
  END-OF-DEFINITION.

  DATA :
    ls_fieldcat   TYPE slis_fieldcat_alv,
    lt_fieldcat   TYPE slis_t_fieldcat_alv,
    lt_event_exit TYPE slis_t_event_exit,
    ls_event_exit TYPE slis_event_exit.

  m_fieldcat 'ERNAM'.
  m_fieldcat 'MATNR'.
  m_fieldcat 'ERSDA'.
  m_fieldcat 'BRGEW'.

  CLEAR ls_event_exit.
  ls_event_exit-ucomm = gc_refresh.    " Refresh
  ls_event_exit-after = c_x.
  APPEND ls_event_exit TO lt_event_exit.

  CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
    EXPORTING
      i_callback_program       = sy-cprog
      i_callback_pf_status_set = 'PF_STATUS_SET'
      i_callback_user_command  = 'USER_COMMAND'
      it_fieldcat              = lt_fieldcat
      it_event_exit            = lt_event_exit
    TABLES
      t_outtab                 = gt_mara.

ENDFORM.                               " F_DISPLAY_DATA
*---------------------------------------------------------------------*
*       FORM USER_COMMAND                                             *
*---------------------------------------------------------------------*
FORM user_command USING u_ucomm     TYPE sy-ucomm
                        us_selfield TYPE slis_selfield.     "#EC CALLED

  CASE u_ucomm.
    WHEN gc_refresh.
      PERFORM f_read_data.             " Refresh data
      us_selfield-refresh    = c_x.
      us_selfield-col_stable = c_x.
      us_selfield-row_stable = c_x.
  ENDCASE.

ENDFORM.                    "user_command
*---------------------------------------------------------------------*
*       FORM PF_STATUS_SET                                            *
*---------------------------------------------------------------------*
FORM pf_status_set USING ut_extab TYPE slis_t_extab.        "#EC CALLED

  DELETE ut_extab WHERE fcode = gc_refresh.

  SET PF-STATUS 'STANDARD_FULLSCREEN' OF PROGRAM 'SAPLKKBL'
      EXCLUDING ut_extab.

ENDFORM.                    "pf_status_set

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;otw,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Set 'X' to selfield-refresh?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
RS_SELFIELD-REFRESH = 'X'. "Structure SLIS_SELFIELD
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HTH&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;Dhruv Shah&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Mar 2008 10:18:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-report/m-p/3581294#M862160</guid>
      <dc:creator>dhruv_shah3</dc:creator>
      <dc:date>2008-03-18T10:18:20Z</dc:date>
    </item>
    <item>
      <title>Re: ALV Report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-report/m-p/3581295#M862161</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 take one refresh button in the function menu bar,&lt;/P&gt;&lt;P&gt;and on its click event just&lt;/P&gt;&lt;P&gt;call the fetching data function and&lt;/P&gt;&lt;P&gt;the display data function of alv.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;your purpose of refreshment wiil be solve.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;like&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; WHEN 'REFRESH'.&lt;/P&gt;&lt;P&gt;      REFRESH final.&lt;/P&gt;&lt;P&gt;      PERFORM fetch_data."fetching data into final internal table&lt;/P&gt;&lt;P&gt;      PERFORM dis_data."display function of alv&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Dhatmishta&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Mar 2008 10:49:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-report/m-p/3581295#M862161</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-18T10:49:37Z</dc:date>
    </item>
    <item>
      <title>Re: ALV Report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-report/m-p/3581296#M862162</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 ALV, to refresh the table you have to call the method "refresh_table_display".  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It has the syntax very similar to creating the table.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It has two parameters. In the first one, you can mention if you want to refresh only the data (the icons are not refreshed)  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if you want to refresh only the icons around the grid (the data is not refreshed - this option is mostly not used in day to day applications). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the synatx is :- &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call method grid (name of grid )-&amp;gt;refresh_table_display &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;exporting &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IS_STABLE = &amp;lt;STRUCT OF TYPE LVC_S_STBL&amp;gt; (THIS IS FOR DATA REFRESHING) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I_SOFT_REFRESH = &amp;lt;VARIABLE OF CHAR 01&amp;gt;  (THIS IS FOR ICON REFRESHING). &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>Tue, 18 Mar 2008 11:04:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-report/m-p/3581296#M862162</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-18T11:04:23Z</dc:date>
    </item>
  </channel>
</rss>

