Grids/Endgrids

Grids are used in Survox’s web programs any time you want to put more than one question on the screen at the same time.

By default, grids require that all questions be answered. You may specify that particular questions may be unanswered by using the question subype “BLANK_OK” on that question, or you may specify GRID,BLANK_OK if you wish to allow all questions to be left blank or unanswered.

Grids may have a ROTATE/!ENDROTATE block inside of a GRID to rotate lists of attributes to be rated or other items on FIELD questions. Grids show any answers previously responded to, even when backing up to the grid. Without a grid, some questions will not keep their answers when you back up to them. Therefore, some questionnaires have every question that requires a response contained inside of a GRID.

You will often build HTML “tables” for formatting inside of grids. The tables are generally used to group similar questions so that they are formatted in columns and rows. The HTML syntax starts with “<table>” and ends with “</table>”.

When you make web pages inside of GRID statements, keep in mind how much information you want to display per page; if you display too much information, the respondent will have to do a lot of scrolling. If you don’t put enough questions on each page, the respondent will have to click on the “next” button more often.

A few additional rules to using Grids:

  • We recommend that all GRID statements have a label; A label on the ENDGRID statement is optional
  • You can include conditions on the GRID statement that applies to all questions on the page
  • You cannot skip “INTO” a grid but you can goto a Grid label
  • You cannot skip “OUT” of a grid
  • You cannot rotate grids using a !ROTATE statement
  • Any Javascript calls must be inside of the GRID/ENDGRID statements
  • Any ENDGRID_ERROR statements must be inside of the GRID/ENDGRID statements
  • You cannot program EXPRESSION, GENERATE, or Alias type of questions inside of GRID/ENDGRID statements
  • You cannot set HTML_DEFINE variables inside of the GRID/ENDGRID statements
  • Grid statements do not take up any data locations and will not be displayed in the CHK file

EXAMPLE:

{ GRIDLABEL:
!IF CONDITION (OPTIONAL)
!GRID }

QUESTIONS...

{!ENDGRID }