Hmm, agree but now let it be as this requires many changes in code as well as here.
Anyways original ListUtils extension has only few functions.
Hmm, agree but now let it be as this requires many changes in code as well as here.
Anyways original ListUtils extension has only few functions.
Are these from my extension? my extension dont have sort list with sort order block.
I do have SortListAtoZ block and working fine.
it's from another extension with same name. That's why @Anke ask you to change to another name.
Ahh, ok I got it. I will make some changes. Thanks.
Yes, the first one (and you should actually know that yourself ).
I got confused about second block.
I have updated the name and topic.
I'm sorry, I hate to break it to you, but almost every single block in this extension can be replicated with built-in blocks. Here is my approach in some of the blocks, there are still more that I haven't tried but can be replicated. Still, nice effort. (gave a like)
I agree, most of the things can be done without extension, but the only difference is extension makes it easier in few blocks as inbuilt blocks need some complicated logic and for pro Koders like us don't need extension.
Anyone who find this useful can use.
I can see your efforts in above blocks!
If any single block from my extension finds useful for anyone, that's enough for me. At least it makes me feel I have not wasted my time.
I like a well defined function signature.
I might copy your interfaces in blocks, while continuing to avoid extensions in my samples.
UPDATED
Updated v2
Added 2 new blocks.
Get First n items and Get last n items to get first specified number of items and last specified number of items from the given list respectively.
Updated v4
That's a good extension.
Can you add the function that I can give certain items a category and then sort by these categories in the listviewer?
Thanks in advance
Provide an example.
I have a list with several elements.
For example, if an element has "apple" in the text, then the element should be added to the category "fruit". This allows you to have several categories in a list viewer.
Like a shopping list that is sorted by categories such as "vegetables", "meat", "fruit" and so on
If I understood you correctly, you have a list of elements (apple, broccoli, chicken, orange, beetroot, carrot) and another list of their categories (fruit, vege, meat, fruit, vege, vege)
No w you want to sort them as per category, by fruit then result will be (apple, orange); by vege (broccoli, beetroot, carrot)
Like this?