I cant move newly created columns to specific locationsI cant make my code work. I am trying to move some newly created columns to specific locations but I get the next error:
"Unrecognized key word"
Do you guys have any ideas of whats wrong here?
ColDelta=(ColNum-2)/2;
ColStart=4;
For(k=1, k<=ColDelta, k++,
TabData << Move Selected Columns(
Column (ColNum+k), after(Column(ColStart))
);
ColStart=ColStart+3;
);
Automation and ScriptingRe: I cant move newly created columns to specific locationsTry adding curly braces, like this:
ColDelta=(ColNum-2)/2;
ColStart=4;
For(k=1, k<=ColDelta, k++,
TabData << Move Selected Columns(
{Column (ColNum+k)}, after(Column(ColStart))
);
ColStart=ColStart+3;
);Re: I cant move newly created columns to specific locationsPerfect! It worked perfectly. Do you have an explanation on why or when I should use the curly braces?
Re: I cant move newly created columns to specific locationsWell, kind of. I tried them, because it can take a list of columns. In this case, it seems to want even a single column in list format.
Re: I cant move newly created columns to specific locationsYou might find syntax information sometimes from JMP Help Scripting Guide > Data Tables > Work with Columns > Rearrange and Move Columns or JSL Syntax Reference (can be found from JMP Documentation page)
