cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Don’t miss your chance to experience Discovery Summit Europe at our best available rate! Early bird registration through 31 Oct.
  • Image to Table JMP extension imports single or batch images as data tables. Useful to extract curves from pictures or convert image data to curve data to use in analyses like Functional Data Explorer. Download and install the extension.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar
FN
FN
Level VI

Closing a hidden data table when closing a figure

I have a few hidden data tables that I only show to the user via some plots.

 

As they are hidden, they accumulate in memory (as many times as the user calls the function in the toolbox).

 

Is there a way to embed the JSL action (closing the invisible table) when the user closes the figure created?

 

1 ACCEPTED SOLUTION

Accepted Solutions
jara95
Level III

Re: Closing a hidden data table when closing a figure

You can just use a On Close method like below,

 

dt = Open( "$SAMPLE_DATA/Big Class.jmp",private );
obj = dt << Bivariate( Y( :Weight ), X( :Height ) );
obj<<on close(close(dt,NoSave));

View solution in original post

2 REPLIES 2
jara95
Level III

Re: Closing a hidden data table when closing a figure

You can just use a On Close method like below,

 

dt = Open( "$SAMPLE_DATA/Big Class.jmp",private );
obj = dt << Bivariate( Y( :Weight ), X( :Height ) );
obj<<on close(close(dt,NoSave));
David_Burnham
Super User (Alumni)

Re: Closing a hidden data table when closing a figure

There is a problem with this approach.  Closing the bivariate window occurs after the script has finished execution.  At that point the variable 'dt' may or may not exist.  This is a more robust approach:

 

dtName = dt << Get Name;
rep = obj << Report;
Eval(Parse(EvalInsert("\[ 	
	rep << On Close(
		Close(DataTable("^dtName^"),NoSave)
	);
]\")));

 

 

 

-Dave

Recommended Articles