--- capa/capa51/GUITools/scorer.tcl 2000/02/22 18:10:27 1.12 +++ capa/capa51/GUITools/scorer.tcl 2000/04/27 20:19:46 1.13 @@ -26,6 +26,11 @@ proc scorerMessage { num mesg {tag norma proc scorerError { num errorCode args } { global gScorer switch $errorCode { + INVALID_CAPAID { + lappend gScorer(errortype.$num) $errorCode + lappend gScorer(errors.$num) [lindex $args 0] + scorerMessage $num "Student [lindex $args 1]'s paper had an unknown CapaID" error + } LOTS_OF_ANON_MODE_MATCHES { lappend gScorer(errortype.$num) $errorCode lappend gScorer(errors.$num) [lindex $args 0] @@ -1038,9 +1043,14 @@ proc handleStudent { num answerStructVar scorerError $num LOTS_OF_ANON_MODE_MATCHES "$answerStruct(orignalLine)" \ $answerStruct(StudentNumber) return 0 + } else { + if { [llength $answerStruct(questionPID)] == 0 } { + scorerError $num INVALID_CAPAID "$answerStruct(orignalLine)" \ + $answerStruct(StudentNumber) + return 0 + } } } - set answerStruct(Name) "$answerStruct(LastName) $answerStruct(FirstName) $answerStruct(MiddleInitial)" scorerMessage $num "Getting Possible Answers for $answerStruct(StudentNumber), paper# $answerStruct(SerialNumber). . ."