Forum Discussion
How to send quiz results via mail automatically via Javascript
Dear Karin and all,
this javascript is definitely working and showing each quiz question result (true means the questions was answered incorrectly)
I created for each Question a variable like "Q5_2" what means Questions Number 2 of the 5th Chapter in the module. So I know what questions it is.
Then the 5 events are created on the very final result slide when timeline starts by "if variable changes then assign the Score Percentage to the variable r1" and so on.
So I am just filling all 5 variables with the 5 score percentages as I have 5 result slides within my module. You perhaps need just one.
Then in the end the learner hits the button, the javascript starts and creates the email with subject, and email text. Email text contains after Validation Code 1 the passing percentages. But I somekind of pasted filling figures to not let the learner understand that these are his final results. So he is not able to modify them.
After validation code 2 each question results are shown with the number of the question. true means a correct answer. False an incorrect answer.
See attached screenshot (German) of an example of a generated email. This is created after the learner hits a button that starts the following javascript.
Good Luck ;)