ekopriyanto 4 Posted July 26, 2016 Report Share Posted July 26, 2016 Hello, anyone can help me to solve how to make ubot visiting list from text file from number to number. If I have 100 list from one text file and I want to choose from number 5 to number 10 only I visit. ui open file("your file", #open)clear list(%urls)add list to list(%urls, $list from file(#open), "Delete", "Global")set list position(%urls, 0)loop($list total(%urls)) { navigate($next list item(%urls), "Wait") comment("your code goes here.")} thank you Quote Link to post Share on other sites
HelloInsomnia 1103 Posted July 26, 2016 Report Share Posted July 26, 2016 You can set list position to be the line number you want - 1 and then loop for the maximum line number - minimum line number. So if you want line 5-10 then you would do 5-1 = 4 so list position 4 then 10-5 = 5 so 5 loops. The reason is that the list starts counting at 0 and not 1. So keep this in mind, list position 4 is going to be line 5 in the file. Here is your example but using what I've said above: ui open file("your file",#open) clear list(%urls) add list to list(%urls,$list from file(#open),"Delete","Global") set list position(%urls,4) loop(5) { navigate($next list item(%urls),"Wait") comment("your code goes here.") } Quote Link to post Share on other sites
ekopriyanto 4 Posted July 27, 2016 Author Report Share Posted July 27, 2016 thank you.. great support 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.