Is there a way to script this menu command: Columns/Reorder Columns/Original Order .
In the JSL manual, I found :
In need to restore the column order to orignal order before Data Table update and reorder it by name after the update.
It's unusual to have a menu command without a JSL equivalent. But if it's not there (I didn't check), you can make use of 'MainMenu()':
dt = Open("$SAMPLE_DATA/Big Class.jmp");
dt << ReorderByName;
dt = CurrentDataTable();
MainMenu("Cols:Reorder Columns:Original Order");
The best place to check out this kind of stuff is 'Help > Scripting Index', which usually has useful examples too, should you need them:
Clearly I need to use it more often myself . . .