Ghoast 0 Posted June 22, 2012 Report Share Posted June 22, 2012 I'm using the random list item command to select and item from a list. After this item has been selected randomly and used once I want it to be deleted so it cannot be randomly selected again. How do I do this? Thanks Quote Link to post Share on other sites
a2mateit 395 Posted June 22, 2012 Report Share Posted June 22, 2012 Not really sure what your trying to accomplish and it took a little playing around with... If you are trying to randomly use proxies and not use the same one twice this is it: clear list(%list) ui open file("Your List", #list) add list to list(%list, $list from file(#list), "Delete", "Global") set list position(%list, $rand(0, $list total(%list))) change proxy($list position(%list)) comment("whatever else here before you need to delete the list item") remove from list(%list, $list position(%list)) Or if you want to navigate to a random site and then remove it, this is it:clear list(%list) ui open file("Your List", #list) add list to list(%list, $list from file(#list), "Delete", "Global") set list position(%list, $rand(0, $list total(%list))) navigate($list position(%list), "Wait") comment("whatever else here before you need to delete the list item") remove from list(%list, $list position(%list)) Not sure what you are trying to accomplish, but this should put you in the right direction... Let me know if you need anymore help, Justin 6 Quote Link to post Share on other sites
celavey 1 Posted June 22, 2012 Report Share Posted June 22, 2012 Great post, a2mateit. This is really quite useful. Quote Link to post Share on other sites
a2mateit 395 Posted June 22, 2012 Report Share Posted June 22, 2012 Thank you. I do what I can to help the community... I know it is easier to see and play with working code, then to have to figure it all out on your own. Quote Link to post Share on other sites
Kazzo 9 Posted June 23, 2012 Report Share Posted June 23, 2012 Hey buddy, i've tryed to get this working for me .. i m trying to use a proxy then remove it from list. I've runned your 1st example but seems that isn't working. I'm getting an error on this step change proxy($list position(%list)) : "Index was outside the bounds of the array". Any ideas what's wrong? Not really sure what your trying to accomplish and it took a little playing around with... If you are trying to randomly use proxies and not use the same one twice this is it: clear list(%list) ui open file("Your List", #list) add list to list(%list, $list from file(#list), "Delete", "Global") set list position(%list, $rand(0, $list total(%list))) change proxy($list position(%list)) comment("whatever else here before you need to delete the list item") remove from list(%list, $list position(%list)) Or if you want to navigate to a random site and then remove it, this is it:clear list(%list) ui open file("Your List", #list) add list to list(%list, $list from file(#list), "Delete", "Global") set list position(%list, $rand(0, $list total(%list))) navigate($list position(%list), "Wait") comment("whatever else here before you need to delete the list item") remove from list(%list, $list position(%list)) Not sure what you are trying to accomplish, but this should put you in the right direction... Let me know if you need anymore help, Justin Quote Link to post Share on other sites
a2mateit 395 Posted June 23, 2012 Report Share Posted June 23, 2012 Did you load the list in the ui panel? Working fine on my end... Quote Link to post Share on other sites
RATPFINK 3 Posted June 24, 2012 Report Share Posted June 24, 2012 (edited) Hey buddy, i've tryed to get this working for me .. i m trying to use a proxy then remove it from list. I've runned your 1st example but seems that isn't working. I'm getting an error on this step change proxy($list position(%list)) : "Index was outside the bounds of the array". Any ideas what's wrong? I think the problem is the list item command needs to be in their. As the code is now the bot will change the proxy or try to navigate to the list position which is just a number. The code should be written to return the list item AT the list position. As follows:clear list(%list)ui open file("Your List", #list)add list to list(%list, $list from file(#list), "Delete", "Global")set list position(%list, $rand(0, $list total(%list)))change proxy($List item (%List)$list position(%list))comment("whatever else here before you need to delete the list item")remove from list(%list, $list position(%list)) Or if you want to navigate to a random site and then remove it, this is it: clear list(%list)ui open file("Your List", #list)add list to list(%list, $list from file(#list), "Delete", "Global")set list position(%list, $rand(0, $list total(%list)))navigate($List item (%List)$list position(%list), "Wait")comment("whatever else here before you need to delete the list item")remove from list(%list, $list position(%list Since I only have a standard license I dont have code view, and I don't know how to make a cool HTTP box like a2mateit so I had to write out the additions manually. Hope I got the format right. The important thing is you must have it return the list item, in other words the text at the list position not just the position itself. This is whats working for me anyway. Thanks for this info as it helped me figure out exactly how to do what I needed to do. Edited June 24, 2012 by RATPFINK 1 Quote Link to post Share on other sites
prosperer888 1 Posted June 29, 2012 Report Share Posted June 29, 2012 i new with ubot...how can i delete a proxy on the first line after i use it and next loop the script get another proxy from the first line and delete it after i use it and so on....i already watch the tutorial videos and didn't find the answer. Quote Link to post Share on other sites
VaultBoss 310 Posted October 22, 2012 Report Share Posted October 22, 2012 In any case, guys... don't forget to decrease the upper limit of the RAND command if you delete an element after using it... (if you're looping the list, that is...) Quote Link to post Share on other sites
Twitter Dominator 125 Posted October 30, 2012 Report Share Posted October 30, 2012 any way to remove bad proxies in line after it tests it if it fails then remove that line from the list? how would you do this adjustment? 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.