cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Try the Materials Informatics Toolkit, which is designed to easily handle SMILES data. This and other helpful add-ins are available in the JMP® Marketplace
Choose Language Hide Translation Bar

On Open script to save file

I'm pretty new to JMP scripting.  Here's what I'm attempting to do.
When I open a .jmp file, I have an On Open script.  This opens a datatable, generates a control chart, and saves the chart to an HTML file.

I'm getting this message.  Is there any way to bypass this message?

Screenshot 2024-09-07 142605.png

3 REPLIES 3
jthi
Super User

Re: On Open script to save file

Is there some specific reason why the control chart is saved with On Open script instead of when the table is created/updated?

 

For Tables there is Evaluate OnOpen Script preference you could change but I would NEVER set it to Always instead of Prompt (I think it should even be set as Never) as there could be pretty bad issues caused by it

jthi_0-1725734740700.png

https://www.jmp.com/support/help/en/18.0/#page/jmp/preferences-for-data-tables.shtml

jthi_1-1725734835373.png

 

-Jarmo

Re: On Open script to save file

Thank you.  I tried this, same results
As for the reason, I'm trying to automate generating many of these where the chart output file will be presented on display boards.

 

In the end I want the On Open script connect to an SQL database, pull the new values into the datatable, create the charts, save the chart to file, close all automatically by just launching the jmp file.

 

Maybe there is a better way?

jthi
Super User

Re: On Open script to save file

You could have a script which does all this, so no need to utilize On Open

  • Open your table
  • perform sql query
  • Update the table
  • create charts
  • save charts
  • and close everything

You can have JSL script which auto-executes if you start it with //!

https://www.jmp.com/support/help/en/18.0/index.shtml#page/jmp/run-a-script.shtml

-Jarmo