<?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: Open Multiple files in different folders in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Open-Multiple-files-in-different-folders/m-p/688649#M87443</link>
    <description>&lt;P&gt;Here is a beginning script that does what you want.&amp;nbsp; It should give you a good start on developing a robust script.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );

// Find the top directory to get the xlsx files from
path = Pick Directory();

// Read in all of the file names
allFiles = Files In Directory( path, recursive( 1 ) );

// Create a list of just the xlsx files
xlsxFiles = {};
For Each( {file}, allFiles,
	If( Word( -1, file, "." ) == "xlsx",
		Insert Into( xlsxFiles, file )
	)
);

// Open each of the xlsx files one after another
// using the Excel Wizard
For Each( {file, i}, xlsxFiles,
	Open( path || xlsxFiles[i], "excel wizard" )
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Thu, 19 Oct 2023 13:30:02 GMT</pubDate>
    <dc:creator>txnelson</dc:creator>
    <dc:date>2023-10-19T13:30:02Z</dc:date>
    <item>
      <title>Open Multiple files in different folders</title>
      <link>https://community.jmp.com/t5/Discussions/Open-Multiple-files-in-different-folders/m-p/688618#M87438</link>
      <description>&lt;P&gt;I have experimental results in 2 different formats as excel files under different folders depending on the conditions of the experiment. Is there a way for the user to state the parent directory and then JMP will open all the excel files as data tables?&lt;/P&gt;&lt;P&gt;I also need need to be able to state the row the data starts on depending on which format the file is so that the column names are correct.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have tried using workflow but I'm not able to use it for more than 1 file and I have tried the importing multiple files function but this only allows access in to 1 folder.&lt;/P&gt;</description>
      <pubDate>Thu, 19 Oct 2023 10:48:16 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Open-Multiple-files-in-different-folders/m-p/688618#M87438</guid>
      <dc:creator>MedianRooster10</dc:creator>
      <dc:date>2023-10-19T10:48:16Z</dc:date>
    </item>
    <item>
      <title>Re: Open Multiple files in different folders</title>
      <link>https://community.jmp.com/t5/Discussions/Open-Multiple-files-in-different-folders/m-p/688649#M87443</link>
      <description>&lt;P&gt;Here is a beginning script that does what you want.&amp;nbsp; It should give you a good start on developing a robust script.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );

// Find the top directory to get the xlsx files from
path = Pick Directory();

// Read in all of the file names
allFiles = Files In Directory( path, recursive( 1 ) );

// Create a list of just the xlsx files
xlsxFiles = {};
For Each( {file}, allFiles,
	If( Word( -1, file, "." ) == "xlsx",
		Insert Into( xlsxFiles, file )
	)
);

// Open each of the xlsx files one after another
// using the Excel Wizard
For Each( {file, i}, xlsxFiles,
	Open( path || xlsxFiles[i], "excel wizard" )
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 19 Oct 2023 13:30:02 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Open-Multiple-files-in-different-folders/m-p/688649#M87443</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2023-10-19T13:30:02Z</dc:date>
    </item>
  </channel>
</rss>

