Delay Between Commands

Hi there,

I would like move the current tab to the end, duplicate the tab, then select the duplicated tab (which is now the last tab). I came up with 2 solutions, however - neither of this work for some reason. Suggestions please?

Go TABPOS=last
Go TABDUPLICATE
Go TABPOS=last

Go TABPOS=last
Go TABDUPLICATE
Go TABSELECT=last

It seems to work in a script... Change from standard function to script function in button/menu setup and add...

[code]@script jscript

function OnClick(ClickData)
{
var cmd = ClickData.Func.Command;
cmd.RunCommand("Go TABDUPLICATE");
cmd.RunCommand("Go TABPOS=last");
}[/code]

Look at that! Works great. Thank you for your reply, yonder.

Slighty semi-off-topic: "go tabpos" looks like an interesting command. But following doesn't seems consistent: while go tabpos=first & go tabpos=last work as intended, i would expect
"go tabpos=2" to choose the second tab. But actually it chooses the third tab, while "go tabpos=1" is activating the second tab. Looks like this would need some little fixing.

[quote="abr"]Slighty semi-off-topic: "go tabpos" looks like an interesting command. But following doesn't seems consistent: while go tabpos=first & go tabpos=last work as intended, i would expect
"go tabpos=2" to choose the second tab. But actually it chooses the third tab, while "go tabpos=1" is activating the second tab. Looks like this would need some little fixing.[/quote]

Nothing needs fixing there.


Thanks, Leo. The part explains it then, with 0 being the first, etc.

Try this script button, it works here, a simple button did also not work for me (third command seemed to be ignored).

[code]@script jscript

function OnClick(data){
data.func.command.RunCommand("Go TABPOS=last");
data.func.command.RunCommand("Go TABDUPLICATE");
data.func.command.RunCommand("Go TABPOS=last");
}
[/code]

Excuse my useless post, I opened that thread 4h before answering, in the meantime you sorted it out, which I didn't see! o)