NIPO ODIN Version 5.17

*SAVE (question option)

Purpose

Saves the answer of a question in a variable.

Syntax

*SAVE <var>

Description

This command is always used in combination with *QUESTION and must be specified after this command on the same line. The answer on a question is saved in a variable. If it is a numeric variable the code value or the number is saved. If it is a text variable with a closed question with precoded answers the label of the code is saved. Saving an answer text is particularly of use if you want to insert this text in a subsequent question (dynamic text modification).

May not be used in a single question in combination with *SAVE as a code option. If used on a *MULTI question, it saves the highest selected code (text) only.

Arguments

var
Any (alpha)-numerical variable or anyof the ten system variables. If the argument is omitted system variable 0 is used by default.

Example

*TEXTVARS PARTY
*QUESTION 5 *CODES 81 *SAVE PARTY
Which party will you vote for in the next election?

1: Conservative union
2: Social democrats
3: Liberals
4: Greens
5: Communists

6: Other party *OPEN
7: None *GOTO 7

*QUESTION 6 *CODES 82
Did you also vote for the *? PARTY in the previous election?

1: Yes
2: No

*QUESTION 7
...

See Also