*** NOTE: ALL INFORMATION IS ACCURATE AT DATE OF PUBLISHING ***
I’ve written about, and done presentations on using Variables in your Forms Pro surveys. We can use them in so many places, but one area that was lacking was the ability to pass through a variable and then use it in a branching rule. This would then give us the ability to show or hide questions even before the recipient responds to any questions. Well, awesome news, we can now do this! Let’s look at how we can combine branching rules with a variable.
First, create your survey. In this example it’s a survey to send out when a product has been purchased. We have two questions that will only be shown if a specific product is purchased. Create the questions that should only be shown when a variable has a specific value, and set the visible toggle to off so the question is hidden by default.
Next, go to the ellipsis (three dots) on the top right and click on Survey variables.
Add in your new variable. Add something in the default value field. You will need to use Power Automate to set this when generating your survey invitation. So for this example, the trigger might be the creation of a new order record or the closure of an order, the closure of a case, or whatever you have in your own environment (CDS, SharePoint etc.) that makes sense. To test your survey, you can add in the value you want to use to make sure the questions show or stay hidden.
Next we need the branching rule or rules. For this we can define the condition and pick Survey variable as the option to trigger on. Then pick the variable, and add in the value that the rule should run on.
If the condition is met, and the product is ‘Expensive Laptop’, we will show two questions to make sure the respondent was offered the extended warranty and additional support plan. If the condition is not met, those two questions will remain hidden.
To test it, you can create a flow in Power Automate to create and send out a survey invitation, being sure to populate the variable (which you can see how to do in a whole heap of other posts). Alternatively, and a faster way, go back to the ellipsis and your Survey variables, and add a value for your variable that does NOT match your condition in the branching rule. You should see your survey with the question hidden.
Now go back to the variable and add in the value that DOES MATCH the condition set in your branching rule. Now the two questions are displayed as expected. Having the ability to use variables in this way is huge! Nice work Forms Pro team!
Check out the latest post:
Creating Personalised Thank You Pages For Realtime Marketing Forms
This is just 1 of 426 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.