bool SetAnswer(Int32 inQuesIdx, Dvar inValues)
Relevant for all question types. Sets the value of an answer/answers in question inQuesIdx with inValues. If the question is of type Multiple Selection or a grid (Single Choice Grid, Numeric Grid etc) it will set the relevant answers with the corresponding values in inValues. First answer will be set with the first value, second answer will be set with the second value etc.
The following is a list of parameters the functions receives
|inQuesIdx||Int32||Target Question Index|
|inValues||DVar||The values to set|
- If question 5 is a Single Choice question SetAnswer(QRef(5),2) will set the second value as the answer
- Assuming question 5 is a Numeric Grid SetAnswer(QRef(5),2,5,7) will set the first topic with the value 2, the second topic with the value 5 and the third topic with the value 7.
- Assuming question 5 is a Single Choice Grid with 3 or more topics and 7 choices then SetAnswer(QRef(5),2,5,7) will set the first topic with the 2nd choice, the second topic with the 5th choice and the third topic with the 7th choice