"ShortAnswer" (Question Interface Type)
"ShortAnswer" (Question Interface Type)
"ShortAnswer"
provides an input field for a free-form answer.
Properties
- In QuestionInterface["ShortAnswer",props], props is an Association that supports the following keys:
-
"Prompt" None text asking the user a question "FieldType" Expression type for input field - Additionally, options for InputField are supported including:
-
Background Automatic input field background color FieldHint Null expression to display when the input field is empty FieldSize {{20., 20.},{1.,Infinity}} the size of the input field
Corresponding AssessmentFunction
- "ShortAnswer" is not an automatically assigned interface type for an AssessmentFunction. It must be specified in QuestionInterface.
Examples
open all close allBasic Examples (2)
Create a short answer question:
QuestionObject[QuestionInterface["ShortAnswer", <|"Prompt" -> "What is your favorite movie?", "FieldType" -> String|>]]A short answer question with assessment:
QuestionObject[QuestionInterface["ShortAnswer", <|"Prompt" -> "What year did Marie Curie win a Nobel Prize?", "FieldType" -> Number|>], AssessmentFunction[{1903}]]