Jump to content
UBot Underground

Setting List Position after loop?


Recommended Posts

Hello.

 

I'm trying to loop a list until it finds  what is in my variable then set the list position to where it found it. But everytime it sets the list position its either 0 or 45 then length of my list.

 

Really stuck on this one, here's my code.

 

Thank you!

 

Edit: Just solved it, I used contains instead of comparison and just set my Variable to set ListCounter instead of list position.

loop($list total(%Scrape1)) {
    if($comparison($list item(%Scrape1, #ListCounter), "=", #BoardNeeded)) {
        then {
            set(#Listlistlist, $list item(%Scrape1, #ListCounter), "Global")
            set(#ListPositionNeeded, $list position(%Scrape1), "Global")
        }
        else {
        }
    }
    increment(#ListCounter)
}

Edited by blacksabbath
Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...