*** NOTE: ALL INFORMATION IS ACCURATE AT DATE OF PUBLISHING ***
Using Variables in Forms Pro gives form creators a way to personalise surveys being sent to respondents. Since Forms Pro first came on the scene, variables have existed and could be added to a survey, but it was limited. Gradually we have seen more and more options added, with variables becoming increasingly more flexible. I’ve put together a list of ten ways variables can be used to create personalised and powerful surveys.
First, let’s look at how a variable is created. From the top right of your survey, click on the ellipsis (three dots) and then Survey variables.
From here we can see all of the variables linked to the survey. The three below are set up as default, but only the locale variable can be deleted (more on this one later in the post). To add another variable, simply click on the +New variable option. Give your variable a name, and then enter a default value, This will be used in the event that you have used a variable but not passed a value through into the survey.
Variables must be populated… either by the default value you set up on the survey (see above), or by using Power Automate and passing the variable through when you generate a Survey Invitation. You can use up to 15 variables (at the moment… which includes the First Name, Last Name and locale variables). Now let’s look at where you can add them, and how they can be used.
After adding your Survey Title, you can then add a description. Simply click on the Variables drop down to add one in. Use this section to address the recipient of the survey invitation by populating their First Name. Or, add variables to show information that you would like the respondent to confirm. Provide the details in the description, then ask a choice questions asking them to confirm that all the info is correct.
We can add variables directly in to the question text. Use the respondent’s name, or add in new variables to display data that pertain to the feedback being given.
Each Survey Question can also have a subtitle. This can be used to add more descriptive text that provides more detail about the question. Use the ellipsis to the right of your question to access the Subtitle option if you don’t immediately see it.
Use your survey variables in email templates that you set up in Forms Pro. Again, to make sure the values are displayed correctly, you must then use Power Automate to generate the survey invitations using the Send a survey action in your flow. Check out this post for more details on how to create a flow like this.
A survey can be embedded in a web page in a variety of ways. You have the option to embed it compact or full size, inline, button or popup. You can also use variables to pass through and retrieve from any of the survey responses received. Check out this post to find out how.
As mentioned at the start of the post, one of the default variables is the locale variable. Forms Pro surveys can be created with multi-lingual versions, so using the locale variable provides us with the mechanism to determine which version to display. Check out this post to find out how to use it.
Once you pass the variables through the survey invitation, they will be returned back through in the survey response. So if you then need to do anything with them, you can. The variables are stored as a value in the Context Data field on the Survey Response record. You can easily get this from the record if you use a model-driven Power App (D365CE) but you can still get to it without this access if needed. If you have access to CDS you can follow some steps in this blog to figure out how to get it, and if you don’t have access to CDS you can follow this blog.
We can use variables in conjunction with branching rules. When adding a condition to a rule on your survey, the condition can start with a question or a survey variable. Make sure you pass the variable through when generating your survey invitation using Power Automate. You can find out more in this post here.
Variables can be added to the end of a survey URL, creating a somewhat personalised survey experience without generating a personalised survey invitation link. You can add the variable into the survey itself which will display the value you appended to the URL. This means you could create one survey, and use it over and over again but create a different experience each time just by changing the URL string. Check out this post to find out how to use this functionality.
Last but not least, we can use variables to connect surveys together. By adding a hidden variable, we can then use it to combine survey responses from multiple surveys, even combining the data together to display and analyse in a Power BI report. Check out this post for more details.
Any other places you would love to be able to use Variables? How are you using them in your Forms Pro surveys?
Check out the latest post:
Top Productivity & Brand Building Tools of 2021
This is just 1 of 323 articles. You can browse through all of them by going to the main blog page, or navigate through different categories to find more content you are interested in. You can also subscribe and get new blog posts emailed to you directly.