Code: Select all
focus;
sel 1;
while(1==1) {
sel +1;
}
Thanks, Tim
Code: Select all
focus;
sel 1;
while(1==1) {
sel +1;
}
Which means you could do:admin wrote:The current implementation is: when the end of the list is reached the last item is unselected, but the focus stays on it (focus must be on any item if there are items).
Code: Select all
focus;
sel 1;
while(Compare("<curitem>", "<focitem>") == 0) {
sel +1;
}
BTW, CountToken() is on my list and will come soon...TheQwerty wrote:It looks like you want to do something for every item currently visible, so an alternative is to use Report() or GetInfo(), and then GetToken() with a while loop that breaks when the token is empty.
TheQwerty wrote:Which means you could do:admin wrote:The current implementation is: when the end of the list is reached the last item is unselected, but the focus stays on it (focus must be on any item if there are items).It looks like you want to do something for every item currently visible, so an alternative is to use Report() or GetInfo(), and then GetToken() with a while loop that breaks when the token is empty.Code: Select all
focus; sel 1; while(Compare("<curitem>", "<focitem>") == 0) { sel +1; }
Bumpadmin wrote:BTW, CountToken() is on my list and will come soon...
Code: Select all
$path = "<curpath>";
$parent = regexreplace($path, '^.+\\([^\\]+)$', '$1');
//$grandparent = gettoken($path, -2, "\");
msg $parent;
Later...Stefan wrote:Bumpadmin wrote:BTW, CountToken() is on my list and will come soon...
Found this thread while searching for GetToken() with negative index
which would start the search from the end.
gettoken(string, [index=1], [delimiter=" "])
If index is negative, the returned token will be the part from the index'th token from the right till end of string.
Code: Select all
$path = "<curpath>"; $parent = regexreplace($path, '^.+\\([^\\]+)$', '$1'); //$grandparent = gettoken($path, -2, "\"); msg $parent;