Smart solution Mark!

Added to TW-Scripts.

On Saturday, August 3, 2019 at 12:30:01 AM UTC+4:30, Mark S. wrote:
>
> 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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/41005933-9387-481f-ba29-3c8d67d8b189%40googlegroups.com.

Reply via email to