<?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: Not able to close table in a for loop in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Not-able-to-close-table-in-a-for-loop/m-p/603319#M80649</link>
    <description>&lt;P&gt;If I remember correctly Multiple File Import returns a list and if that is the case you will have to loop over that list while closing the data tables.&lt;/P&gt;</description>
    <pubDate>Tue, 21 Feb 2023 05:50:57 GMT</pubDate>
    <dc:creator>jthi</dc:creator>
    <dc:date>2023-02-21T05:50:57Z</dc:date>
    <item>
      <title>Not able to close table in a for loop</title>
      <link>https://community.jmp.com/t5/Discussions/Not-able-to-close-table-in-a-for-loop/m-p/603249#M80645</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I want to use a for loop to keep import multiple files and close it after concatenate. the import multiple and concatenate is working but not the close(). I tried wait(), still not working. Not sure what I did wrong.&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt1 = New table();
dir = {"dir1","dir2","dir3"}; //can have many dirs
for(i=1, i&amp;lt;= N Items(dir), i++,
	dt[i] = Multiple File Import(
	&amp;lt;&amp;lt;Set Folder( path1||"\" || dir[i] ),
	&amp;lt;&amp;lt;Set Show Hidden( 0 ),
	&amp;lt;&amp;lt;Set Subfolders( 0 ),
	&amp;lt;&amp;lt;Set Name Filter( "*.csv*;" ),
	&amp;lt;&amp;lt;Set Name Enable( 1 ),
	&amp;lt;&amp;lt;Set Add File Name Column( 1 ),
	&amp;lt;&amp;lt;Set Add File Size Column( 0 ),
	&amp;lt;&amp;lt;Set Add File Date Column( 0 ),
	&amp;lt;&amp;lt;Set Import Mode( "CSVData" ),
	&amp;lt;&amp;lt;Set Charset( "Best Guess" ),
	&amp;lt;&amp;lt;Set Stack Mode( "Stack Similar" ),
	&amp;lt;&amp;lt;Set CSV Has Headers( 0 ),

	) &amp;lt;&amp;lt; Import Data,


dt1 &amp;lt;&amp;lt; Concatenate(dt[i],Append to first table( 1 ));

close (dt[i],nosave); //this is the step dont seems taken effect. table not close
);&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 08 Jun 2023 16:34:32 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Not-able-to-close-table-in-a-for-loop/m-p/603249#M80645</guid>
      <dc:creator>dadawasozo</dc:creator>
      <dc:date>2023-06-08T16:34:32Z</dc:date>
    </item>
    <item>
      <title>Re: Not able to close table in a for loop</title>
      <link>https://community.jmp.com/t5/Discussions/Not-able-to-close-table-in-a-for-loop/m-p/603319#M80649</link>
      <description>&lt;P&gt;If I remember correctly Multiple File Import returns a list and if that is the case you will have to loop over that list while closing the data tables.&lt;/P&gt;</description>
      <pubDate>Tue, 21 Feb 2023 05:50:57 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Not-able-to-close-table-in-a-for-loop/m-p/603319#M80649</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2023-02-21T05:50:57Z</dc:date>
    </item>
  </channel>
</rss>

