<?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: changing alv source table in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/changing-alv-source-table/m-p/2704614#M626521</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You are going to want to destroy all of the objects every time the PBO is fired. It is the easiest way to rebuild the ALV.  Make sure that you are clearing(CLEAR) the reference variables as well as freeing(FREE) them.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 14 Aug 2007 14:20:43 GMT</pubDate>
    <dc:creator>RichHeilman</dc:creator>
    <dc:date>2007-08-14T14:20:43Z</dc:date>
    <item>
      <title>changing alv source table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/changing-alv-source-table/m-p/2704612#M626519</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 a screen with a I/O textfield and a custom container.&lt;/P&gt;&lt;P&gt;It's supposed to list in alv the table that's in the textfield.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm using the cl_salv_table class to display the alv, it works fine the first time but when I change the name at the textfield it just do nothing.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the t_table parameter is always correct when it reaches the method factory.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm kinda lost, I've tried many things but nothing seems to work.&lt;/P&gt;&lt;P&gt;here's my source code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;  DATA: CC_1400_REG type ref to cl_gui_custom_container.
  data: gr_table2     type ref to cl_salv_table.

  check not io_tabname is initial.

  IF not gr_table2 IS initial.
    gr_table2-&amp;gt;refresh( ).
  else.

  create object CC_1400_REG
    exporting
      container_name = 'CC_1400_REG'.

  TRY.
    CALL METHOD cl_salv_table=&amp;gt;factory
      exporting
        r_container      = CC_1400_REG
        container_name   = 'CC_1400_REG'
      importing
        r_salv_table     = gr_table2
      changing
        t_table          = &amp;lt;TABLE&amp;gt;.
  CATCH CX_SALV_MSG.
  ENDTRY.
  gr_table2-&amp;gt;display( ).
endif.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE&gt;&lt;/TABLE&gt;&lt;P&gt; is a fs pointing to a dinamicly created internal table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i've already tried to free the container and the cl_salv_table each time PBO is executed but nothing works...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;those anybody knows how can I solve this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;best regards,&lt;/P&gt;&lt;P&gt;André Costa&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Aug 2007 14:10:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/changing-alv-source-table/m-p/2704612#M626519</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-14T14:10:13Z</dc:date>
    </item>
    <item>
      <title>Re: changing alv source table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/changing-alv-source-table/m-p/2704613#M626520</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;Refresh the container and dynamic internal table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your code for generating the new ALV list should be in PBO.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think the dynamic internal table is not regenerated.You can check this in debugging mode.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward if helpful.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Aug 2007 14:18:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/changing-alv-source-table/m-p/2704613#M626520</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-14T14:18:50Z</dc:date>
    </item>
    <item>
      <title>Re: changing alv source table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/changing-alv-source-table/m-p/2704614#M626521</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You are going to want to destroy all of the objects every time the PBO is fired. It is the easiest way to rebuild the ALV.  Make sure that you are clearing(CLEAR) the reference variables as well as freeing(FREE) them.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Aug 2007 14:20:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/changing-alv-source-table/m-p/2704614#M626521</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2007-08-14T14:20:43Z</dc:date>
    </item>
    <item>
      <title>Re: changing alv source table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/changing-alv-source-table/m-p/2704615#M626522</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Uma sankar . S : Could you tell me how to refresh the container?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rich Heilman : Still not working... here's my code with "your" changes:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;  DATA: CC_1400_REG type ref to cl_gui_custom_container.
  data: gr_table2     type ref to cl_salv_table.

  check not io_1400_nome is initial.


 FREE gr_table2.
 FREE CC_1400_REG.
  create object CC_1400_REG
    exporting
      container_name = 'CC_1400_REG'.

  TRY.
    CALL METHOD cl_salv_table=&amp;gt;factory
      exporting
        r_container      = CC_1400_REG
        container_name   = 'CC_1400_REG'
      importing
        r_salv_table     = gr_table2
      changing
        t_table          = &amp;lt;TABLE&amp;gt;.
  CATCH CX_SALV_MSG.
  ENDTRY.
  gr_table2-&amp;gt;display( ).&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The internal table &amp;lt;table&amp;gt; is reaching this point properly...&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Andr Costa&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Aug 2007 14:28:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/changing-alv-source-table/m-p/2704615#M626522</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-14T14:28:07Z</dc:date>
    </item>
    <item>
      <title>Re: changing alv source table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/changing-alv-source-table/m-p/2704616#M626523</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try this.....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;


  DATA: CC_1400_REG type ref to cl_gui_custom_container.
  data: gr_table2     type ref to cl_salv_table.
 

CLEAR gr_table2.            FREE gr_table2.
CLEAR CC_1400_REG.   FREE CC_1400_REG.


check not io_1400_nome is initial.

* move clear and free before this CHECK statement.
  




&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Or are these defined directly in the module of the PBO?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Aug 2007 14:51:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/changing-alv-source-table/m-p/2704616#M626523</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2007-08-14T14:51:58Z</dc:date>
    </item>
    <item>
      <title>Re: changing alv source table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/changing-alv-source-table/m-p/2704617#M626524</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN __jive_emoticon_name="sad"&gt;&lt;/SPAN&gt; no... still not working...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and no, this is from a FORM called at PBO.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and btw, the check statement is just to avoid the shortdump at the first call of the screen (because there is no name at that field...)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Aug 2007 15:00:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/changing-alv-source-table/m-p/2704617#M626524</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-14T15:00:59Z</dc:date>
    </item>
  </channel>
</rss>

