I think this answers your question as described in your text -- note that it specifies both numbers to compare. It uses pre20
<$vars selected=7 whereami=8> <$list filter="[range[1,10]allbefore<selected>match<whereami>]"> <<whereami>> is before selected item <<selected>><br> </$list> <$list filter="[range[1,10]allafter<selected>match<whereami>]"> <<whereami>> is after selected item <<selected>><br> </$list> </$vars> On Friday, August 2, 2019 at 5:41:33 AM UTC-7, Mohammad wrote: > > A partial solution > > <$set name=selected value=7> > <$list filter="[range[1,10]]" variable="item" > > <$list filter="[range[1,10]allbefore<selected>] +[prefix<item>]"> > <<currentTiddler>> is before selected item: <<selected>><br> > </$list> > </$list> > </$set> > > > > This works, any better idea? Any TW intrinsic solution? > > > --Mohammad > > On Friday, August 2, 2019 at 4:59:10 PM UTC+4:30, Mohammad wrote: >> >> I have a list of tiddlers, I iterate over the list and I want to know if >> an item is before or after the selected item! >> >> How to do this? >> >> >> --Mohammad >> > -- You received this message because you are subscribed to the Google Groups "TiddlyWiki" group. To unsubscribe from this group and stop receiving emails from it, send an email to tiddlywiki+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/23269a20-7d24-4ad1-8f77-9081ccf068bb%40googlegroups.com.