How do you make a quiz in one screen?

i dont found for checkbox(i solved my problem)

what blocks i use for when i click on checkbox correctly i saw textlabel "is correct" and nextbutton became visible

Code the example quiz to automatically advance to the next question by creating a Procedure advanceToNextQuestion . Call it as shown at the green arrow in the score Procedure. If you answer correctly, you advance to the next question. :slight_smile: If you answer incorrectly :cry: the user needs to use the NextQuestion button (Button1) to move on to the next question or select the correct answer CheckBox.

next button is invisible, when i click correct answer becomes visible

Perhaps now is the time for you to use the advice here> Programming Your App to Make Decisions and try some things on your own instead of copying code. Experiment. Save a copy of your Project and modify it. Test the code and make the app work like you want it to. :slight_smile:

Something like nextButton.visible = false then correct_answer.visible . Sorry, I don't understand what you mean by making the correct answer visible.

when i click correct answer the nextbutton is visible

Coding like you suggest makes it impossible to move to the next question unless the user answers a Quiz question correctly (checks the right answer check box). The app can be coded to only show the Next Question button when an answer is correct. It requires a few changes. However, when coded to display this way, a user cannot advance in the Quiz unless he/she answers correctly. If he/she answers incorrectly the Next Question button is not visible to display the next question.

Are you certain you want to do this? This behavior messes up the scoring already programmed and forces the user to keep checking CheckBoxes until he / she happens on the solution by chance.

Did the Procedure showing how to automatically display the next question following a correct answer work for you? Did you try coding that? That code does what you asked for "how to active "next question" when i click correct answer"

when user click wrong answer I dont want them to advance, would make the quiz pointless

Change and/or add these Blocks exactly. These changes might** do what you want.**

OK, they won't advance. :cry:


why give me this error: The operation select list item cannot accept the arguments: , [""], [2]
Note: You will not see another error reported for 5 seconds.

A guess is the error is related to one of the Blocks with a red ?

  • You didn't copy all the suggested Blocks or make the changes correctly.
  • You modified the Quiz questions/answers incorrectly
  • Your version of the app is different from my version; you changed other stuff

You are trying to select the second item of an empty list somewhere in your blocks

i use this blocks

Sorry @MudMic . You changed how the questions are set up. That is probably your problem. I cannot fix the Lists for you. A huge guess is you entered 2 in this Block; it might require a 6 ???

Here is a version of the original simple checkbox quiz. The aia uses two different text/csv files to provide two question sets. You can have as many question sets as you desire.

correct wrong

Use your own code Blocks and fix them or use the model shown here and not worry about your incorrect Blocks and bug. Have fun.

Unlike your version of the app, this app Works!!! Try the aia please.

MyQuiz2abcd.aia (41.3 KB)

1 Like

i tryied this aia but how i change the csv file with lists, i don't want to use text file or csv file

The operation select list item cannot accept the arguments: , ["Question?"], [6]
Note: You will not see another error reported for 5 seconds.

You need to adapt this aia to use Lists yourself or wait for someone who wants to debug your app.
This DoIt offers a possible clue as to how to set up your Lists to work with my aia.

Good luck. :slight_smile:

Learn to debug your project yourself...

use Do it to debug your blocks, see also tip 4 here App Inventor: How to Learn | Pura Vida Apps
see also Live Development, Testing, and Debugging Tools

Trying to push the limits! Snippets, Tutorials and Extensions from Pura Vida Apps by icon24 Taifun.

After checking the AIA, I found event, but couldn't find it on the Components window.

Button1 is 'hidden' in the VerticalArrangement