Forum Documentation Showcase Pricing Learn more

How to Show Quiz Results?


#1

Hi, Dear Bubble users! As a newbie I need your help.

I am building simple quiz application that captures the user’s answers and summarizes results.

Currently I have built the workflow that saves the answers to the related data type.

But I am not able to show the summary of the quiz. For example in a quiz I have 10 questions and each of them equals to 1 point. Therefore, I need to show how many points the user earned as a result of the quiz.

Appreciate your help very much!


#2

Any ideas?


#3

Hi @nshikhaliyev - not sure how many quizzes a user can take (and therefore how many quiz scores to keep track off) but here are two thoughts/scenarios:

  1. If the User has only one quiz score, then add a data field (of type number default to = 0) called “Quiz Score” (or whatever). Every time a correct answer is made, have a Workflow step to increment “Quiz Score” by 1. If the user retakes the quiz, remember to add a Workflow step to set “Quiz Score” back to 0.

  2. If the user has multiple quiz scores, create a type called “User Quiz Scores”. There’d be multiple fields within “User Quiz Scores”

  • Student Name (type User)
  • Score (type number, default = 0)
  • Quiz ID (type text or if you have a Custom Data Type for “Quiz” then type would be “Quiz”)

Then under User Data Type, add new Data Field called “User Scores” of type “User Quiz Scores”. You’d check off the “This field is a list” so the Data Field is a List of “User Quiz Scores”. When a quiz starts, you’d need to have a Workflow step to create a new “User Quiz Score” and fill in the Student Name and Quiz ID. You’d also need a Step to add “User Quiz Scores” to User’s Data Field List of “User Scores” so you keep a list of that User’s quizzes in the database. As the User progresses thru the quiz, have a Workflow step to increment Score for each correct answer.

Hope these ideas made sense and help you develop your quiz app.
tx
Nikolai
Echo Lake Technologies


#4

Thank you very much for your help Nikolai!


#5

Dear Nikolai,

I followed your suggestions but seems that I am missing something important.

As you suggested every time a user gives correct answer the workflow should increment the score to 1.

Currently I am not able to increment the score to 1. How to tell the app which of the answer is correct and how to increment each time the right answer is given? I am not able to build correct workflow.

Regards,
Nurlan


#6

Hi @nshikhaliyev - can you provide an image of your Workflow Steps that you currently have for incrementing the quiz score.

If the quiz score is under User, you should have a Workflow step like the image below. Note the image is from a quick mockup which uses “Total Rating Sum”. You’d have something like “Quiz Score = Current User’s Quiz Score + 1”
tx
Nikolai

image


#7

Dear Nikolai,

Thank you very much for your help! I almost lost my hope to solve this issue.

My idea is to build an app which gives an opportunity for recruiters to send invitations to job applicants and test their knowledge. At the end recruiter should be able to compare results of several applicants.

  1. I added group with radio buttons. In each test there is one correct answer.

  1. Then I created “test result” data type which contains question question number". This field is intended to save test results.

  1. At the end of the test there is “complete” button which creates new thing in “test result” data type.

What I need to do is to indicate which is the correct answer and give +1 to each correct answer for the user.

Appreciate your help!

Regards,
Nurlan


#8

Hi Nurlan - looking at your workflows, it looks like you’re only allowing quiz takers to go forward to the next quiz question (and not back to previous questions). As such, here are my suggestions.

  1. When “Next 1” workflow occurs, I would create a new Test Result for that user in that workflow (and not the “Complete SJT CC” workflow). I assume “Next 1” moves the user to Question 2. In this same workflow step, I would check if the user got the correct answer and if so, add 1 to Result. You also want to make a change to Current User (ie the Quiz taker) and add Test Result to that User in the database. So in the database under User you’d have “Test Results” of type “Test Result”.

  2. When “Next 2” thru “Next 7” Workflows occur, I’d also check the answer and add 1 to Result. This would be a “Make Changes to Test Results” step in the workflow (not a "Create New Test Result as you do in “Next 1” Workflow). In these steps you’ll have something similar to below where you add 1 to “Current User’s Test Results Result” instead of the “Total Rating Sum” I show below (cut/pasted from a demo app I have).
    You will also need to add something for “Only when” where you check that the answer is correct below you add 1 to Test Results Result
    image

With these suggestions you could give the quiz taker quicker feedback on their score, ie put a text field with their score. Not sure if that’s needed for your app…
These suggestions should get you most of the way there.
tx
Nikolai
Echo Lake Technologies
How-to Video Library


#9

Many thanks Nikolai. I implemented your suggestions except one issue.

It seems that I cannot tell the app which answer is correct . As you suggested I tried to use “only when” condition to check correct answer. I indicated the correct choice from one of the radio buttons as App Text . But in this case app assigns +1 value to all of the answers without checking whether the answer is right or not.

Seems like I am missing some element in using “only when” function.


#10

Hi Nurlan - I created a little mockup which may help you. Here’s the setup for “RadioButtons A”. It has 4 choices
image

I have a simple text field which has default of RadioButton’s A value
image

Here’s the part that’ll help you with your “only when” conditional. Below is the conditional for the text field. Depending on what button is chosen, the text will change. Note I didn’t put quotes around the text - Bubble does that.

I think you’re close with your design. I’m assuming “SJT CC Answer 1’s” is your RadioButton? Looks like the issue is after the “contains” statement. Make sure the text after “contains” is identical to the correct answer. Note you can have partial text - in my example I only look for the answer number, ie “1)”.