If I am interpreting your code properly, what you are doing is copying your limits from the limits table, into the column properties for your data table. If this is the case, you may want to look at the Manage Spec Limits capability in JMP 14
Manage Spec Limits( );
However, if you just want to continue the way you are doing it, here is a modification of your script that will set the Show Limits
Names Default To Here( 1 );
dt = open();
dt2 = Data Table( "limits" );
Current Data Table( dt );
nw = New Window( "Select Process Variables",
Text Box( "Selection Columns" ),
H List Box(
datacolbox = Col List Box( all ),
Button Box( "Process Variables", pList << append( datacolbox << get selected ) ),
pList = List Box( {} )
),
Button Box( "OK",
thelist = plist << get items;
// Loop across all of the item is theList and process
// the data
For( i = 1, i <= N Items( theList ), i++,
theRow = dt2 << get rows where( :Process == theList[i] );
If( N Rows( theRow ) > 0,
// Change theRow to a scaler
theRow = theRow[1];
// Set the spec limits in the dt data table by reading
// the values from the dt2(limits) data table
Eval(
Substitute(
Expr(
Column( dt, theList[i] ) <<
set property(
"spec limits",
{__LSL__, __USL__, __Target__, Show Limits( 1 )}
)
),
Expr( __LSL__ ), Column( dt2, "LSL" )[theRow],
Expr( __USL__ ), Column( dt2, "USL" )[theRow],
Expr( __Target__ ), Column( dt2, "Target" )[theRow]
)
);
);
);
nw << close window;
)
);
Jim