How do I complete the insert column with JSL?The script index could not be found.Thank you!
For example: insert a two-column numeric format column to the left of column 2.

Re: How do I complete the insert column with JSL?Exactly the kind below is needed.
Thank Jim!Re: How do I complete the insert column with JSL?You can use "Move Selected Columns()" to move a column that you have added to the end of your data table. However, just as with the "Add Multiple Columns" the choices are focused on adding after a column. So you would have to subtract 1 from your position, and then use that value as the insert position
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
dt << New Column("The New Column", set selected)
Wait( 2 );
dt << Move Selected Columns( after(as column(1)) );
// or
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
dt << Add Multiple Columns( "Added ", 2, after(as column(1)), numeric );Re: How do I complete the insert column with JSL?Okay,Thank Jim! but my point is to insert directly to the left of column 2.
Can I create a new column at the end and move it around with code?Re: How do I complete the insert column with JSL?The "Insert Columns" functionality is handled by "Add Multiple Columns" . It is located under "Data Table > Data Table Cols" in the Scripting Index