I need help to finish an app (select items randomly from a List)

Hello, could someone help me set up an app? What I want to do is to press a button that shows random results of lists. I would appreciate if someone helps me.

Do you mean you want to randomly select an item from a List of items churro?

Use Blocks similar to these for a simple case:
randomListItem
Place the set global random… blocks into a Button1.Click event handler. Set a Label.txt to randomSelection to display it.

Exactly what you need to do depends on your List. What have you tried?

Here are some resources to help you learn to use the AI2 tools A very good way to learn App Inventor is to read the free Inventor’s Manual here in the AI2 free online eBook http://www.appinventor.org/book2 … the links are at the bottom of the Web page. The book ‘teaches’ users how to program with AI2 blocks.

There is a free programming course here http://www.appinventor.org/content/CourseInABox/Intro and the aia files for the projects in the book are here: http://www.appinventor.org/bookFiles

How to do a lot of basic things with App Inventor are described here: http://www.appinventor.org/content/howDoYou/eventHandling .

Also look here http://kio4.com/appinventor/index.htm and here http://www.imagnity.com/tutorial-index/ for more tutorials.

Regards,
Steve

2 Likes

Or did you want to generate an entire random list?

Hi, thanks for answering. Sorry for my English. My idea is basically a screen where the TRUTH, CHALLENGE buttons are. When pressed, show a result, that is, a garment to comply.
I wanted every time I press the button to randomly display results so that the sequence is not repeated in the order I create it. So with each button. Thank you

Hi, thanks for answering. Sorry for my English. My idea is basically a screen where the TRUTH, CHALLENGE buttons are. When pressed, show a result, that is, a garment to comply.
I wanted every time I press the button to randomly display results so that the sequence is not repeated in the order I create it.

Take a look here:

2 Likes

Maybe you want to shuffle a list?
[(Shuffle Lists & Unique Random Numbers | imagnity)]