Adding questions to profilers

There are four different types of questions or groups of questions that can be used in a profiler – single questions, grid questions, validation groups and address groups.

Question Type Description
Single Question A single question is the basic question which uses one variable.
Grid Question A grid question is used for groups of coded variables which have the same answer options so that they can be displayed in a grid with the questions listed down the side and the answer options across the top.
Validation Group A validation group allows variables to be grouped together for validation purposes.  The user can specify the minimum and/or maximum number of questions that require an answer.
Address Group If the installation uses the Postcode Web custom plugin, an address group can be used to map each part of the address to the fields retrieved by the postcode search.

The properties of Single Questions described below are common to all questions.  The additional properties of the other question types are covered later in this article.

Single Questions

Single questions are the most basic type of question using one variable.

To add a new question to a page first select the required page then click on the New Question button from the toolbar.

The New Profiler Page Question dialog will appear.

Enter the properties of the question using the following fields:

Variable

This field displays the variable to be used for this question.  The variable is selected using the Select button, or cleared using the Clear button.

To add a new question, use the Select button to display the Variable Selection dialog box which will show all the variables available. 

Find the variable you require either by navigating to it by expanding the appropriate folders, or by performing a variable search.

Select the variable and click on OK.  The variable and associated question will be added to the profiler page question dialog.

The variables that are shown in the Variable Selection dialog are defined in Hierarchy Manager, which can be found within the Maintenance menu.  In order to be available for use in a profiler, a variable must have the ‘Allowed in Profilers’ check box ticked.
New variables can be added using the Q_Panel Data Import service or by using Variable Manager.

Question

This field will display the question associated with the selected variable.  This is the question that will be displayed on the profiler when it is run.

The text of a question can be changed using Variable Manager in the Maintenance menu.

Css Class

To use a particular CSS stylesheet for the question, the code name of the stylesheet (as defined in Site Manager/Development/CSS Stylesheets) should be entered here.

Exclusive Answer

Exclusive Answer is only available if the selected question can have multiple answers, i.e. is a multi-coded question, in which case a dropdown box will be available to allow the selection of one of the possible answers to be the exclusive answer.  When running the profiler, the panellist will not be able to select any other answer at the same time as the exclusive answer. 

The default value is None, which means there is no exclusive answer.

Container Markup

To add or change the markup language around the question click on the Show/Change button.  The Content Container Editor will be displayed.

A question content marker is provided by default which can be added to, removed and/or formatted as required.

As before, there are three views: Design (default), HTML and Preview. The Design view is a near-WYSIWYG editor; HTML allows you to edit the HTML code directly; Preview shows you the results of your editing in a non-editable preview mode.

The other buttons in the Design view have standard editing functions.

Input is read-only

If this check box is ticked the question will be disabled – when running the profiler the panellist will be able to see the question and the answer that is already stored in the database (if it is already populated) but will not be able to make changes.

Input is hidden

If this check box is ticked the question will be hidden – when running the profiler the panellist will not see this question at all.  The question can still be used as a routing condition.

Is Answer Required?

If this check box is ticked the question is mandatory and a Required Message must be selected. By default, this option is unchecked which means the question is optional.

Required Message

A required message can only be selected if the Is Answer Required? check box is ticked.  Click on the "..." button to display the Profiler Messages dialog, where an existing message can be selected, or a new message added.

Display Control Properties

This area is used to define the way the question will be displayed on the profiler for the panellist to enter.  Depending on the type of variable selected, this may include validation rules and messages.

From the Display Control Properties dropdown box select a Display Control Type. Only control types relevant to the type of variable selected will be available.

For more information about Display Control Types see related article.

Click on OK to return to the Edit Profiler screen.  Edit Profiler now displays the page with a + next to it.  Click on this to expand the list to show the new question.

At this point the new question has not been saved, so it is a good idea to click on Save to save the changes to the profiler.

It is not possible to add questions to the pre-defined Start, Finish or Complete pages.

Grid Questions

Grid questions can be used for coded questions (single-code or multi-code) where questions with the same possible answers are grouped together and displayed in a grid with the questions down the side and the answer options along the top. 

Single-code questions will display with radio boxes and multi-code questions with check boxes.

In order to work correctly, it is essential that all questions in the grid have the same number of answers, and these answers must all be the same as only one column heading will be displayed.

To add a grid question to a page, first select the required page then click on the New Grid Question button from the toolbar.

The New Profiler Page Grid Question dialog will appear.

Enter the properties of the grid question using the following fields on the Detail tab:

Name

This is a mandatory field and should contain the name of the grid question.  The question name does not need to be unique within a profiler and will not be seen when running the profiler.

Display Question Properties

This area will show the variables that are used in the grid question.  Add a new variable using the Add variable button (+).  Delete a variable from the grid using the Remove variable (X) button.

Display Control Properties

This area is used to define the way the grid question will be displayed on the profiler. Only control types relevant to the type of variable selected will be available.

For more information about Display Control Types see related article.

The way the grid question is displayed on the profiler can also be customized using the Content Container tab.

This dialog allows a particular CSS style sheet to be used for this group of questions by entering the code name of the stylesheet (as defined in Site Manager/Development/CSS Stylesheets).

A group content marker is provided by default which can be added to, removed and/or formatted as required. 

Adding a question to a grid

To add a new question, click on the Add variable button.  The Variable Selection dialog box will be displayed, and will show only variables suitable for use within a grid i.e. coded variables.

Select the variable you require and click on OK.  The variable and associated question will be added to the profiler page question grid dialog.  Once the first variable has been selected, the subsequent variables must be of the same type i.e. single-code or multi-code.

The Display Control Properties dropdown box will default to the relevant Display Control Type for the variable selected. 

(a)    Example using Single-code Variables

We will create a grid question for the single-coded questions Holiday Attitudes. 

  • To do this, first give the grid question a name such as ‘Holiday Attitudes’. 
  • Add the variable HolidayAttitude1 by clicking on the Add Variable button and selecting HolidayAttitude1 from the Variable selection dialog. 
  • Next, click on add again to add HolidayAttitude2.  You will notice that the list of available variables is smaller as only single-coded questions will now be shown.
  • Continue adding until all ten Holiday Attitudes have been added.

As the variables in the grid are single-code values the display control properties defaults to RadioButtonGrid.

You can see all the questions in the grid by using the arrows to scroll back and forth. Each question within the grid can have its own individual properties if required.

  • Click OK to return to the profiler and remember to press Save to save the changes.

When the profiler is run, the question grid will be displayed as follows.

(b)    Example using Multi-code Variables

We will create a grid question for the multi-coded questions Newspaper Attitudes. 

  • To do this, first give the grid question a name such as ‘Newspaper Attitudes’. 
  • Add the first variable NewspaperAttitude1 by clicking on Add Variable button and selecting NewspaperAttitude1 from the Variable selection dialog. 
  • Next, click on add again to add NewpaperAttitude2.  You will notice that the list of available questions is smaller as only multi-code questions will now be shown.
  • Continue adding NewspaperAttitude3 and NewspaperAttitude4.

As the variables in the grid are multi-coded the display control properties defaults to CheckBoxGrid.

You can see all the questions in the grid by using the arrows to scroll back and forth. Each question within the grid can have its own individual properties if required.

  • Click OK to return to the profiler and remember to press Save to save the changes.

When the profiler is run, the question grid will be displayed as follows.

Removing a question from a grid

To remove a question from a grid, click on the appropriate tab within the Display Question Properties area for the variable to be removed, click the Remove variable button.  The tab for the selected variable will be removed.  Click OK to close the dialog and press Save to save the changes to the profiler.

Validation Groups

Profiler questions can be grouped together for validation where the panellist is required to enter an answer for a minimum or maximum number of questions in the group.

To add a validation question to a page, first select the required page then click on the New Validation Group button from the toolbar.

The New Profiler Page Validation Group dialog will appear.

Enter the properties of the validation group using the following fields on the Detail tab:

Name

This is a mandatory field and should contain the name of the validation group.  The group name does not need to be unique within a profiler and will not be seen when running the profiler.

Validation Rules

Questions answered - Min This is the minimum numbers of questions in the group that must be answered by the panellist.  The default value is 0.
Questions answered - Max This is the maximum number of questions in the group that must be answered by the panellist.
Invalid Message
This is the message that will be displayed if the number of questions answered does not meet the validation rules.  If a validation message is not set the default validation message will be used (as defined in UI Cultures).
Select a message using the button (...) or click on remove (X) to clear the message.

Questions

This area of the dialog will show the variables that are used in the validation group.  Add a new variable using the add button (+).  Delete a variable from the group using the remove button (X).

The way the validation group is displayed on the profiler can also be customised using the Content Container tab.

This dialog allows a particular CSS style sheet to be used for this group of question by entering the code name of the stylesheet (as defined in Site Manager/Development/CSS Stylesheets).

A group content marker is provided by default which can be added to, removed and/or formatted as required. 

Validation Group Example

We will create a validation group for phone numbers, where the panellist is required to enter at least one phone number.

  • To do this first give the validation group a name such as ‘Phone Numbers’. 
  • Set the Min to 1 and leave the Max as the default (there is no maximum).  Select or add a suitable validation message by clicking on the select button (...).
  • Add the first variable Home Phone Number by clicking on add (+)  and selecting HomePhoneNumber from the Variable selection dialog.  Select TextBox as the Display Control. 
  • Next, click on add (+)  again to add WorkPhoneNumber, and again for MobilePhoneNumber

Each question within the validation group can have its own properties and specific validation rules if required (depending on the type of variable selected).

  • Click OK to return to the profiler and click Save to save the changes.

When the profiler is run, the validation group will be displayed as follows.

The user will not be able to progress to the next page until at least one of the phone numbers has been entered.

Address Groups

If your installation uses the Postcode Web custom plugin, an address group is required to make use of this facility.  Each part of the address is mapped to the fields retrieved by the postcode search.

In order to use postcode lookup you must have the Postcoder Web custom plugin installed. A subscription to the Postcoder Web service is also required 

(https://www.alliescomputing.com/postcoder/address-lookup).

To add an address group question to a page, first select the required page then click on the New Address Group button from the toolbar.

The New Profiler Page Address Group dialog will appear.

Enter the properties of the address group using the following fields on the Detail tab:

Name

This is a mandatory field and should contain the name of the address group.  The group name does not need to be unique within a profiler and will not be seen when running the profiler.

Is Answer Required?

If this check box is ticked the address is mandatory and a Required Message must be selected. The default value is unchecked which means the question is optional.

Required Message

A required message must be selected if the Is Answer Required? check box is ticked. 

Select a message using the button, or click on to clear it.

Address Question Mapping

This area is used to map the variables in the database to each field of the address.  When the postcode is entered and a match found, the variables specified here will be populated with the relevant part of the address according to this mapping.

Note that the number of address lines to be populated is specified in Setting Manager on the Maintenance menu.

Each variable on each tab of the address mapping can have its own properties.  These are the same as the properties for single questions.

The way the address group is displayed on the profiler can also be customized using the Content tab.

CSS Class Name

Enter the code name of the CSS stylesheet (as defined in Site Manager/Development/CSS Stylesheets) in order to use a particular style sheet for the address.

Search

This is the text that will be displayed on the Search button within the postcode question.  Select the required text using the select button (...), or click on remove (X) to clear it.  If the text is not set, the default text will be used (as defined in UI Cultures).

Select

This is the text that will be displayed on the Select button when the list of possible addresses is displayed.  Select the required text using the select button (...), or click remove (X) on to clear it.  If the text is not set, the default text will be used (as defined in UI Cultures).

Cancel

This is the text that will be displayed on the Cancel button when the list of possible addresses is displayed.  Select the required text using the select button (...), or click remove (X) on to clear it.  If the text is not set, the default text will be used (as defined in UI Cultures).

Content Wrapper

A group content marker is provided by default which can be added to, removed and/or formatted as required. 

Address Group Example

An address group may be set up as follows. 

  • First give the address group a name such as ‘Address’
  • For each of the tabs in Address Question Mapping select the appropriate variable and display control type.  That is, on the AddressLine1 tab click on the Select button and select AddressLine1 from the Variable selection hierarchy and select TextBox as the Display Control Type.
  • Next, click on the AddressLine2 tab to add Address Line 2 and complete the other tabs with an appropriate variable from the database.

Each question within the address group can have its own properties and specific validation rules if required (depending on the type of variable selected).

  • Click OK to return to the profiler and click Save to save the changes.

When the profiler is run, the validation group will be displayed as follows.

When a postcode is entered, the user should click on the Search button to display a list of possible addresses.  The required address may be selected by clicking on the Select button and the address fields will be populated.

Sorting Questions

To change the order that questions are displayed within a profiler page, the Sort function on the Pages tab should be used. 

From the Edit Profiler screen select the required page and expand it out to show the questions by clicking on the +.  Select any of the questions within the page then click on Sort on the toolbar.

A dialog box will appear showing a list of questions for the current page.

To change the sort order click on a question and use the sorting arrows to move it up or down.

Once you are satisified with the order click on the OK button, or click Cancel to leave the order as it was. 

To make the change permanent remember to click on Save before continuing.  Questions will now be displayed in the new order on the Pages tab, and also when running the profiler in Q_Community.

Removing Questions

Questions may be removed from a profiler page.  Unlike profiler pages, questions will be permanently deleted from the profiler and will not be available to restore later (of course, the underlying database variables will not be deleted, and so the question may be re-created at a later time). 

From the Pages tab of Edit Profiler select the required page and expand it out to show the questions by clicking on the +.  Click on the required question then select the appropriate Remove button from the toolbar (the only options enabled will be for the question types selected).

If the question is a single question select Remove Question.

If the question is a grid question select Remove Grid Question.

If the question is a validation group select Remove Validation Group.

If the question is an address group select Remove Address Group.

The question will disappear from the screen.

Questions may only be removed one at a time.

A question cannot be removed if it is used in a routing condition.