Finding a row within a repeater

I have a table that has several rows and the columns:

I want to be able to find the first row in the repeater where the flag is not true.

Is there a way to do this? I’ve tried using a filter, but all my data disappears when I apply it.


Use the “listener” method. A post that details it is here.

So to find the first row where the flag column is not true, you’d set up a variable like v_found, which you will use to keep track of whether the first value has been found yet or not, because the OnMoved event will be executed on every row in the repeater, and we don’t want to act on the second or third instance of a non-flagged row.

On Moved (of listener in repeater)
  If value [[Item.flag]] is not equal to true AND v_found is equal to false
    -- do what you want to do here when the first non-true flag is found
    set v_found equal to true

Because v_found is set to true upon finding the first instance, the condition will fail for every subsequent row.

Then, outside of the repeater, you’d say…

On Click (or whichever event)
  set v_found to false
  move (listener widget in repeater) by 0,0

Thanks… this worked perfectly!

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.