Sanjeev 46 Posted April 2, 2013 Report Share Posted April 2, 2013 if($comparison($list position(%testList), "=", $list total(%testList))) { then { set list position(%testList, 0)-----------if($comparison($list position(%testList), ">=", $list total(%testList))) { then { set list position(%testList, 0) Thanks. Quote Link to post Share on other sites
LoWrIdErTJ - BotGuru 904 Posted April 2, 2013 Report Share Posted April 2, 2013 if comparison ( list total + 1 > list total)then set list position 0elsenothing Quote Link to post Share on other sites
Sanjeev 46 Posted April 2, 2013 Author Report Share Posted April 2, 2013 (edited) I am sorry . I'm just a dumb newbie here. I would really appreciate it if you could explain how and why this works...?]do you mean - list position+1 > list total?I find that at end of a list -> list position = list totalThat is why I had enquired about the above statements in the OP.In this case if list total = say 10, then, when end of list is reached - list pos. would also = 10.hence,in your code - we are checking 10+1 > 10?In the same vein I had also thought of checking - if list position = list total? Thanks Edited April 2, 2013 by Sanjeev Quote Link to post Share on other sites
LoWrIdErTJ - BotGuru 904 Posted April 2, 2013 Report Share Posted April 2, 2013 This gives you a better full example clear list(%list) add list to list(%list, $list from text("link link0 link2 link3", $new line), "Delete", "Global") loop(1000000) { if($comparison($add($list position(%list), 1), ">", $list total(%list))) { then { set list position(%list, 0) } else { } } navigate($next list item(%list), "Wait") } this is only reliant if your looping over a list a number of times larger then list total. Otherwise there is no reason to set the list position back to 0 1 Quote Link to post Share on other sites
Sanjeev 46 Posted April 3, 2013 Author Report Share Posted April 3, 2013 Thanks for for such a detailed reply. I really appreciate it! Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.