Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?You could navigate to the check box and control it that way
Names Default To Here(1);
mfi = Multiple File Import(
<<SET folder=""></SET>
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?@jthi Thanks but does not work in JMP 16.2.0 (on Windows 10)
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?Slight modification is needed (and is better for JMP17 also) as JMP17 has different default value change << Set to << Set All
Names Default To Here(1);
mfi = Multiple File Import(
<<SET folder=""></SET>
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?I ran Jarmo's code on JMP 16.2 on Windows 11 and it ran correctly. I was able to set the Keep Dialog Open checkbox to off or on using
checkboxes = (mfi << XPath("//CheckBoxBox"));
checkboxes[N Items(checkboxes)] << Set(0);
or
checkboxes = (mfi << XPath("//CheckBoxBox"));
checkboxes[N Items(checkboxes)] << Set(1);
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?@jthi Your code works for me but I have a connected problem. It appears that the code proceeds without the user pressing the import button. In my case (JMP 16.2 on Win10), the window tilte is shown and the journal window pops up. How to hold progress until the user has pressed the import button.
Names Default To Here(1);
mfi = Multiple File Import(
<<SET folder=""></SET>
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?You might be able to get Multiple File Import inside modal window somehow or you could try using << On Close
Names Default To Here(1);
mfi = Multiple File Import(
<<SET folder=""></SET>
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?@jthi . Thanks. On Close only appear to work in case of the journal window. Does not work for the following for example.
Names Default To Here(1);
mfi = Multiple File Import(
<<SET folder=""></SET>
I need a run a large script after the user selects the files using the Multiple File Import function. The script operates on the selected files. Could I please have the example with Multiple File Import function inside a Modal Window? In this case, how to reference he files opened by Multiple File Import (in my case two files) for further use?
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?Most likely it won't work in your case as the mfi has been closed. I would go with On Close route because modal window will most likely mess up the buttons of Multiple File Import
Names Default To Here(1);
aa_olddt = Associative Array(Get Data Table List() << get name);
mfi = Multiple File Import(
<<SET folder=""></SET>
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?Names (strings) of datatables are stored to dt_list so you have to convert them to data table references when using.
Names Default To Here(1);
//clear log ();
aa_olddt = Associative Array(Get Data Table List() << get name);
mfi = Multiple File Import(
<<SET folder=""></SET>
Depending on your application it might be a good idea to loop over the dt_list (maybe rename it to dtname_list) and create a list of datatable references
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?@jthi Thanks, but how does one call further scripts (e.g to plot etc) to operate on the data tables imported. The first one below works, but this is not what I need.
Names Default To Here(1);
//clear log ();
aa_olddt = Associative Array(Get Data Table List() << get name);
mfi = Multiple File Import(
<<SET folder=""></SET>
I need to be able to call scripts to operate on the imported data files. One below does not work (gives attached error)
Names Default To Here(1);
//clear log ();
aa_olddt = Associative Array(Get Data Table List() << get name);
mfi = Multiple File Import(
<<SET folder=""></SET>
where plotDist.jsl (saved in the same directory) is
Names Default To Here(1);
dt<<DISTRIBUTION></DISTRIBUTION>
Putting
include ("plotDist.jsl");outside On Close also does not work. Where am I going wrong?
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?@jthi Thanks, but as I have indicated above (posted incorrect code first which I have edited), how does one include scripts inside On Close() which call on one of more of the imported data tables?
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?You would loop over your list of data tables and perform the actions. Depending on what you are doing you could build expressions or functions which could then be called inside the loop.
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?@jthi Ok I will try to loop, but where does the loop go - inside On Close () or outside On Close (). Also what does the attached error message mean?
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?Whatever you want to happen after Multiple File Import has been closed, should happen inside On Close. You can make it a bit cleaner by creating functions and expressions outside the On close but then call them inside.
It might be a good idea to accept solution to this post as it has already been solved and post a new one with additional information on what you wish to do after.
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?Example for the Import Callback script
x=Multiple File Import(
<<SET folder=""></SET>
This script runs when the import button finishes; you might need the list of data tables.
You might send MFI a command to <
x<
Extra info:
<
The setup messages are inside the parens for the mfi launch and happen before the window opens; the launch returns an MFI object which the CreateWindow message is sent to; the result from CreateWindow is assigned to x.
Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?Nice info @Craige_Hales !
Scripting index (or rather JMP/JSL documentation) strikes again 

Re: How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?My fault, I'm afraid. I already sent a note to the technical team. It was added after the initial release, for exactly this purpose.How to start Multiple File Import () vis JSL with Keep Dialog Open unchecked?As the tile says - I have tried the following but does not work
Names Default To Here( 1 );
// use the save-script-to-script-window button
// in the MFI dialog to see more messages
// for filtering files and controlling the import
Multiple File Import( Keep Dialog Open (0),
<<SET folder=""></SET>
Where am I going wrong?
Design of Experiments