There are several ways to do this. The following example by Wendy Murphry would mimic the behavior of the recall buttons in other platforms. http://www.jmp.com/support/notes/46/984.html
Perfect. (I'd mark the problem as "Solved", but I didn't start the discussion so I don't think I can.)
Following on from the above post, I'd like to add some functionality to the various Col List Boxes in Wendy's script that would make filling in one of them mandatory, with at least two columns from the data table (so if I were using a Column Dialog to do this, I'd be setting the "min col" option of one of the boxes to 2). In the example they're all optional, and I can't see any properties of a Col List Box that would enable me to do that. Can someone show me how to do it please?
BTW: I don't think I can use a Column Dialog instead, because I need to add other functionality to the dialog as well - and creating a modal window along the lines of Wendy's script seems the easiest way to set it up.
Many thanks for any help received.
The MinItems(n) option for Col List Box will allow you to specify a minimum number of columns for the list. See the Col List Box entry in the JSL Syntax Reference in Appendix A of the JMP Scripting Guide for futher details. You can view this PDF by clicking on the Help menu and select Books > Scripting Guide.
Below is an excerpt from Sample 46984 to demonstrate:
Panel Box( "Cast Selected Columns into Roles",
Lineup Box( N Col( 2 ), Spacing( 3 ),
Button Box( "Y, Response", colListY << Append( colListData << GetSelected ) ),
colListY = Col List Box( width( lbWidth ), nLines( 5 ), numeric, MinItems(2) ), //HERE
Button Box( "X, Factor", colListX << Append( colListData << GetSelected ) ),
colListX = Col List Box( width( lbWidth ), nLines( 1 ), numeric ),
Button Box( "By", colListB << Append( colListData << GetSelected ) ),
colListB = Col List Box( width( lbWidth ), nLines( 1 ) )
Hope that helps!