How to set a control page

Compatibility:IdSurvey 5IdSurvey 6

A control page verifies the coherence of answers given to previous questions.
The page is displayed only if the an incoherence is detected, and it helps respondents to correct wrong answer.

In this example we ask how many employees the company where the respondent works has.
In the next question we ask how many of those employees are men and how many are women.
Control page verifies that total of men and women is the same as number inserted in first question.

Here’s a preview of the questions as displayed to the respondent.

P1
Q1 – How many employees has the company you’re working for?

P2
Q2 – How many of these 10 are women and how many are men?

Men       

Women  

Pcontrol
Qc – Hey! There’s an error.
You said your company has 10 employees but then you indicated 6 men and 5 women.
Please correct wrong answer

 Correct total number of employees

 Correct number of women or men

In this example we have 3 different pages. First page includes an open end question. Second page includes a grid with 2 open ended rows. To run a coherence check we need a third page: a control page. Using a display condition, this page will appear only if the sum of men and women will not match the total number indicated in previous question.

Also, using text piping, we can display in the text of question Q2 and Qc the values inserted in previous questions, making clear to the respondent where the incoherence is. The two single select options of question Qc make the respondent jump back with a skip condition to the answer that needs a correction.

Display conditions on Pcontrol

Page Pcontrol has to be displayed only if answer of question Q1 is different than sum Q2.1 + Q2.2

if( [Q1] != ARITH([Q2.1]+[Q2.2]) )

ARITH function performs math calculations. In this case it sums answers of question Q2, which is sum of men and women indicated.
Symbol != means “different than”.
So: if Q1 is different than sum of Q2.1 + Q2.2, page will be displayed.

Skip condition

In the two single select options of control page you have to set skip conditions to make the respondent jump back to the answer that needs to be corrected.

So, if the respondent clicks on “Correct total number of employees”, IdSurvey will jump back to question Q1; if the respondent clicks on “Correct number of men and women”, IdSurvey will jump back to Q2.

Correct total number of employees GoTo Q1, Pcontrol
Correct number of women or men GoTo Q2, Pcontrol

In the skip condition you have to write GoTo followed by the code of the question that has to be displayed.

In this example there’s a second code after the comma (Pcontrol) that represents the page that will be displayed subsequently. Once the respondent has corrected the answer, another control will be performed: if the sum and the value match, the control page won’t be displayed and the respondent will proceed with following questions.

Text Piping

Customizing question text (or answer text) makes comprehension much easier. In this example we used text piping to display previous answers in following question text. The control page question text says “You said your company has 10 employees but then you indicated 6 men and 5 women”. As you can see numbers displayed are answers given to previous questions.

To use this function in the question text you just have to write:

You said your company has [Q1] employees but then you indicated [Q2.1] men and [Q2.2] women.

Similarly in question Q2 you display answer of question Q1:

How many of these [Q1] are women and how many are men?

/page P1
  
  Q1
 How many employees has the company you're working for?
  
  1  ->T
  
/page P2
  
  Q2 ->T
  How many of these [Q1] are women and how many are men? /rows .1 Men .2 Women /cols 1 /page P3 /F "if(ARITH([Q2.1]+[Q2.2])!=[Q1])" Pcontrol Hey, there's an error!<br />You said your company has [Q1] employees but then you indicated [Q2.1] men and [Q2.2] women.<br />Correct wrong answer 1 Correct total number of employees /C "GoTo Q1, Pcontrol" 2 Correct number of women or men /C "GoTo Q2, Pcontrol"

Using this simple example you can create much more complex control page.

To learn more on display conditions, skip conditions and text piping syntax please check related articles.

Leave A Comment?