Marking unanswered questions

Marking unanswered questions

by Jack Eapen -
Number of replies: 7

I want to mark the unchecked questions in a quiz for an easy review by the participants. ie say, i have 15 questions with 1 question per page and users are navigating to next pages using the pagination links. can we add a special formatting to the page numbers, if that particular question is unanswered? which variable we can use for specifying the unanswered questions?

Jack

Average of ratings: -
In reply to Jack Eapen

Re: Marking unanswered questions

by Jack Eapen -
how can we mark unaswered questions using some special formatting to the question no, so that participants can easily return to those questions?
In reply to Jack Eapen

Re: Marking unanswered questions

by N Hansen -
Vote for bug 5098 and add your comments there.
In reply to N Hansen

Re: Marking unanswered questions

by Jack Eapen -

i voted for this.

but any solutions for the problem, plz?

 

In reply to Jack Eapen

Re: Marking unanswered questions

by Jack Eapen -

i need it badly. going mad dead 

any help, please?

Jack

In reply to Jack Eapen

Re: Marking unanswered questions

by Peter Bulmer -
Sorry Jack, there's no easy fix here.  (IMHO).
If you're able / willing to wade into some moodle code, here's a couple of pointers off the top of my head:
(all of this obviously comes under the usual disclaimers (IIRC ...)

The quiz_newest_state table has a field newgraded, if this is set, the question has been graded. 
If not, the question may have been seen, and answered (saved) but not graded.  You'll need to consult entries in the quiz_states table, and examine the event field (int) - this is set depending on what action the student took that led to the creation of the field.  The action the student took that led to the entry being made in the quiz_states table is called  an event. 
What an event id means is defined (in 1.5.3 at least) in mod/quiz/locallib.php.  I'm fairly certain this is different in 1.6 code, but I don't know that off by heart yet.
If none of the events indicated a saved state, or graded state, then the student has not submitted an answer.
Perhaps you want to identify a page with unaswered questions by a different colour on the paging bar? Up to you.
Hope this helps (you or someone else)
Pete.
In reply to Peter Bulmer

Re: Marking unanswered questions

by Jack Eapen -

Hi

thks Peter for the hints. i have been desperately searching for a solution to mark unattempted questions in a quiz as it progress. I have multiple choice-single answer questions with one question per page, in my timed quiz. Its possible that particpants skip some difficult questions in the beginning and want to return to them after they see all the questions. It would be very helpful for the participants if the unattempted question number links are shown in, say, red color and others in green or so.

I'm not a programmer. i tried many ways to achieve this, but failed. i got some opening in the questiontypes/multichoice/questiontype.php file . there's a function print_question_formulation_and_controls(&$question, &$state, $quiz, $options) and i hope the parameter $state->responses[''] may be used to find unattempted question. if the value of this variable is empty that means the question is not marked with any answer. Now my problem is how can i use this value in the quiz_print_navigation_panel() function defined in quiz/locallib.php file. i want to do something like this:

if ($state->responses[''] =="") { //blank response

$fontcolor="red";

} else {

$fontcolor="green";

}

and use the value of $fontcolor variable in the hyperlink part of the question numbers.

can anyone please tell me how can i pass the value of $state->responses[''] variable (or the $fontcolor) from print_question_formulation_and_controls() function (defined in a class) to the quiz_print_navigation_panel() function (outside the class)? or am i really dumb? there must be some other easy workaround?

Jack

http://www.jackeapen.com/