BookmarkSubscribe
Choose Language Hide Translation Bar
WHTseng
Community Trekker

How to script a dialog box for multiple file?

Hi JMP users,

 

I am looking for a method to select many files, and then point them into different variables.

I don’t think the function Pick File is suitable because I have to set the variables to the data tables one by one.

 

The first thing crossed my mind is file select dialog(like the picture below), I can input the path or select the files from icon.

And point every file to the corresponding variable in script code, no manual selection is needed.

Do you have idea how to make it with JMP script?

dialog.jpg

 

Thank you for all the supports.

0 Kudos
1 ACCEPTED SOLUTION

Accepted Solutions
txnelson
Super User

Re: How to script a dialog box for multiple file?

I would use Pick Directory()

Names Default To Here( 1 );
Pick File(
	"Select JMP File",
	"$DOCUMENTS",
	{"JMP Files|jmp;jsl;jrn", "All Files|*"},
	1,
	0,
	"newJmpFile.jmp"
);

and then the Files in Directory()

 

Files In Directory( "$HOME" );

to get started with what you want to do.

 

Look to the Scripting Index for the examples and definitions

     Help==>Scripting Index

Jim
2 REPLIES 2
txnelson
Super User

Re: How to script a dialog box for multiple file?

I would use Pick Directory()

Names Default To Here( 1 );
Pick File(
	"Select JMP File",
	"$DOCUMENTS",
	{"JMP Files|jmp;jsl;jrn", "All Files|*"},
	1,
	0,
	"newJmpFile.jmp"
);

and then the Files in Directory()

 

Files In Directory( "$HOME" );

to get started with what you want to do.

 

Look to the Scripting Index for the examples and definitions

     Help==>Scripting Index

Jim
WHTseng
Community Trekker

Re: How to script a dialog box for multiple file?

Hi txnelson,

Thank you for the idea.
Files in Directory() indeed gives me the file list so that I can do further selection among them.
0 Kudos