This extension allows for doing more things with App Inventor Lists. I made this extension with Kodular IDE.
Current version: 1
Release date: 2019-04-21T21:00:00Z
Required permissions: none
Min API required: N/A
I decided the build this extension because I saw we can actually do more things with
YailList (a Java object which used in App Inventor for lists.) So I created additional blocks for the built-in list blocks.
||Required List Type
||Return a list which sorted by Bubble sorting algorithm.
||Return minimum number in list.
||Return maximum number in list.
||Return a sorted list for list which contains strings instead of numbers.
true if input lists are same. If not, result will be
||Return last item from any list. It can be useful if you have dynamic list.
||Return a strictly syntactically correct JSON text representation of list.
||Return a reversed list.
I wanted to make a universal extension which will work in all App Inventor distros. So maybe we can have “reverse list” block, but other distros still may not have. That’s why I added this block to the extension.
I didn’t add sorting option because you can already have descending sorting by reversing sorted list.
com.yusufcihan.listaddon.aix (8.7 KB)
I hope you like it! Don’t forget to report the problems. I will try to do my best to improve this extension.
(by the way I love direct links)
Wow nice one
Btw, It’s like this Extension builder should represent their extensions
Thanks for this very useful extension. In this extension sorting order is available in ascending and better if you implement also in descending order.
@7StarMedia The list utils extension by appybuilder also does support descending shorting.
I didn’t add sorting option because you can reverse sorted list then you will have descending sorting.
Maybe I can add sorting option, but this will only increase extension size since you can already select the sorting option.
Can you add sort option for list in list structure?
Liste içinde liste tipi için destek ekleyebilirmisin? Mesela
gibi bir listeyi belli bir item e göre sıralasın mesela en yüksek puana sahip olan puan2 ise isim2 ve e2 yi birinci eleman olarak geri döndürsün gibi.
Göz atmam lazım. Aslında belki bunu mantık ve bloklarla yapabilirsin ancak tam emin değilim.
I need to take a look at it. Maybe actually you can do with logic and blocks, but I’m not sure.
I already do it with blocks but if i can do it with extension its make easier.
Bloklarla yaptım lakin eklenti olması daha çok işime gelir
Thanks again for this extension, I have got the solution, check blocks:
check this video if you want to learn step by step, but this is in Hindi Voice
Thanks, (for like and for video) yeah as I said you can revert sorting with “Reverse” block.
Also you don’t need to create new variable for that. You can use Reverse block with Sort directly. Just connect purple block with purple block.
Thanks for reporting! I fixed it. For preventing the upcoming community download errors, I hosted the file on my website. (Don’t worry, it is a direct download link too )
11 posts were split to a new topic: How to mix list items randomly?
I’m getting an odd issue. I’m sorting a list of names alphabetically using the SimpleSort method and names that have been entered without capitalization get sorted to the bottom of the list. Is there a way to sort it without taking capitalization into account?
As I sort items with Java’s own Sort method, it is case sensitive. I can add a method for that when Kodular IDE becomes online again.
You can lowercase your all list items as a workaround.
I added the TextBoxTools extension to set the box to capitalized words so that it should result in the names being formatted correctly. Hopefully, that solves the issue unless my users intentionally screw it up. Which, to be realistic, they probably will.
Fantastic extension. I like it.
Hi. How to sort
- Water Melon
- Custard Apple
- Custard Apple
- Water Melon
Up to 9 I seems it is possible, But if number increases to double digit or more
the result is not as expected.
I tried for 21 Numbers in this way. The result is as following.
The result is coming like this
Try to use bubble sort method of the extension @indianplans