cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Check out the JMP® Marketplace featured Capability Explorer add-in
Choose Language Hide Translation Bar
dileepkr
Level III

File selection input box in JMP Application builder

Hi,

 

I am creating a JMP application which would open a xlsx workbook, load individual sheets into datatables in background and link the datatables to Graph building JSL script buttons in JMP app. 

Is there a way to create a file selection input box in JMP Application builder, where in user can browse and select the xlsx workbook from the app?

1 ACCEPTED SOLUTION

Accepted Solutions
cwillden
Super User (Alumni)

Re: File selection input box in JMP Application builder

Definitely.  Just create a button box and give it a script that does a pick file. Here, I just have a button box and an empty text box named "file_path_text".  For the button box script, I just type in "On Select".

GUI.pngThen in the script window, I define On Select like so:

script.png

On Select = expr(
	file_path = Pick File(
		"Select Excel File",
		"$DOCUMENTS",
		{"Excel|xls;xlsx"}
	);
	
	file_path_text << Set Text(file_path)
);

When you run it, you should see your selected file printed in the previously empty text box showing the path of your previously selected file.  Use "dt = open(file_path)" to open the selected file when you're script is ready to start working with the selected file.

-- Cameron Willden

View solution in original post

2 REPLIES 2
cwillden
Super User (Alumni)

Re: File selection input box in JMP Application builder

Definitely.  Just create a button box and give it a script that does a pick file. Here, I just have a button box and an empty text box named "file_path_text".  For the button box script, I just type in "On Select".

GUI.pngThen in the script window, I define On Select like so:

script.png

On Select = expr(
	file_path = Pick File(
		"Select Excel File",
		"$DOCUMENTS",
		{"Excel|xls;xlsx"}
	);
	
	file_path_text << Set Text(file_path)
);

When you run it, you should see your selected file printed in the previously empty text box showing the path of your previously selected file.  Use "dt = open(file_path)" to open the selected file when you're script is ready to start working with the selected file.

-- Cameron Willden
dileepkr
Level III

Re: File selection input box in JMP Application builder

Thank you so much for the solution!