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

JSL :: Event handling or Data binding to list boxes

Hello JMP Community,

I am in the middle of designing a GUI which allows to select an input table/ columns and an output table/ columns.  I am strunggeling with on how JSL handles mous clicks:  I want to select a table using a combo box, with a Col List Box updating following the mouse click on the combo box (how does the data binding of the Col list Box occur?).  Please have a look at the attached image for details.

jmp_jsl_q.png

 

Any help apprechiated!

 

Thanks and best,

Thorsten

 

1 ACCEPTED SOLUTION

Accepted Solutions
txnelson
Super User

Re: JSL :: Event handling or Data binding to list boxes

Because of the specifics on the Col List Box(), what I find the best, and maybe the only way to handle the replacement of the data table associated with the object, is to delete the object and to replace it.

Names Default To Here( 1 );
QorvoPE_Select_Table = Function( {},
	table_list = {};
	For( t = 1, t <= N Table(), t++,
		Insert Into( table_list, Data Table( t ) << get name )
	);
	QorvoPE_Select_Table_dlg = New Window( "Select Data Table For Limit Calculation. ",
		<<modal,
		<<return result,
		Panel Box( "Select Table and columns",
			select_table = Combo Box(
				table_list,
				table = select_table << get selected();
				data col clb# << delete;
				MYHLB << append(
					data col clb# = Col List Box( Data Table( select_table << get selected ), all )
				);
			),
			MYHLB = H List Box(
				data col clb# = Col List Box( Data Table( select_table << get selected ), all ), 

			)
		)
	);
);

QorvoPE_Select_Table;
Jim

View solution in original post

2 REPLIES 2
txnelson
Super User

Re: JSL :: Event handling or Data binding to list boxes

Because of the specifics on the Col List Box(), what I find the best, and maybe the only way to handle the replacement of the data table associated with the object, is to delete the object and to replace it.

Names Default To Here( 1 );
QorvoPE_Select_Table = Function( {},
	table_list = {};
	For( t = 1, t <= N Table(), t++,
		Insert Into( table_list, Data Table( t ) << get name )
	);
	QorvoPE_Select_Table_dlg = New Window( "Select Data Table For Limit Calculation. ",
		<<modal,
		<<return result,
		Panel Box( "Select Table and columns",
			select_table = Combo Box(
				table_list,
				table = select_table << get selected();
				data col clb# << delete;
				MYHLB << append(
					data col clb# = Col List Box( Data Table( select_table << get selected ), all )
				);
			),
			MYHLB = H List Box(
				data col clb# = Col List Box( Data Table( select_table << get selected ), all ), 

			)
		)
	);
);

QorvoPE_Select_Table;
Jim

Re: JSL :: Event handling or Data binding to list boxes

Thank you very much!

That helped a lot.

 

Best wishs,

--Thorsten