Important Update to Custom Scripting
The CustomScript Action now supports the LUA programming language. Visit our NEW Lua Scripting Resources!
- New accounts (created after October 29, 2018) will only have the option to use Lua in scripts.
- As of October 29, 2018 Custom Scripting Actions will default to Lua as the scripting type in the Custom Scripting Action for accounts created before this date. You will be able to switch to the Legacy Custom Scripting; though we highly encourage using Lua.
- In the long term, Legacy Custom Scripting Actions will be switched to read-only. The exact date on this is to be determined; we will send notifications well ahead of time.
Alchemer offers a very flexible feature called piping, where chosen answers to source questions are taken forward as answer options, table rows or table columns into subsequent questions.
There are many instances however, where we want to pull through information from previous answers into subsequent questions, but the automatic way will not do. In this section, we have built a usage and attitudes survey on classic video games to illustrate several examples of this.
Sometimes you may want to filter the list of options in your question / table rows or columns in your question based on answers to a previous question. Usually this can be accomplished simply by applying the right piping settings to pipe into the rows of columns of the target question. There are a number of scenarios, however, where it is required to do this in a custom way. For example:
- The target question does not support piping into the option list. For example you have a source checkbox question, the answers to which you want to be displayed as options in a followup textbox list question.
- You want to exclude certain options in the source question from the filtration logic in the target question, or vice-versa.
- The relationship between what is selected in the source question and the target question is not a straightforward one-to-one. I.e. only if respondents ticks option x in question 1, then show options a, b and c in question 2.
Piping From Two Questions Into One
Sometimes it is appropriate to ask two separate questions on slightly different themes, but ask a follow-up question about what the respondents select as a combination. In this case, we set up a script which filters the answer options displaye...
Piping From a Checkbox Into a Grid Question
In this scenario, we are going to set up a custom script to filter the grid rows displayed in a target question based on any corresponding options selected in the source checkbox question. Normally, it would be fine to use standard piping, but here...
Piping: Checkbox Grid to Radio Button Grid
In this example we are going to only show the rows in the target radio button grid questions for which any of a specified set of column answers were checked in the source grid.
For this to work, the target grid question must be setup with row t...
Piping: Radio Button Grid to Radio Button Grid
In this example, we are going to only show the rows in the target radio button grid questions for which any of a specified set of column answers were checked in the source Radio Button Grid.
For this to work, the target Grid question must be se...
Piping: Radio Button Grid Into Checkbox Question
In this example is a script which queries for which rows in a Radio Button Grid respondents answered an option between the values of 6 and 10 and then filter the list of options in the subsequent Checkbox question accordingly. For this to work the t...
Piping from a Checkbox Question Into Multi-Slider
Unfortunately the multi-sliders question does not have piping as a feature, but we can do this through a custom script as illustrated here.
For this to work the target question must be setup with slider option names which correspond to the opti...
Filtering Textbox List by Checkbox Question
As piping into answer options is not available for Textbox List questions, this script will query the answers from a source Checkbox question and filter the option list in a target Textbox List question accordingly. For this to work, the option titl...