Forum Discussion
Mike_C96
Jun 03, 2025Copper Contributor
Power Automate/MS Forms - Checking for blank responses
I've created a MS Form that asks a number of questions, some of which are branched off of others. The responses are pulled using Power Automate and fed into a MS Word doc template that already has the questions and gets populated with the responses. The result is a document with all the possible questions, but only responses from the branch of questions answered based on the individuals' answers.
In an ideal world I'd love for the questions to be pulled from the Form only if there's a response entered, and not if there isn't, but it doesn't seem like that's an option (at least not a relatively easy one). So instead, we want to have Power Automate check each question and if there isn't response, have it display the text "Intentionally unanswered". Is there a way to do this without having to set a condition for each question? There are about 50 questions on the Form and sometimes only half of them end up getting responses.
1 Reply
Sort By
- Surya_NarayanaIron Contributor
Yes, you can handle blank responses efficiently in Power Automate without creating 50 individual condition blocks. Instead, use a single expression or simple logic per field, often within a "Compose" action or directly in the Word document population step.
Here’s how you can streamline it:
Option 1: Use coalesce() to Set Default for Empty Answers
The coalesce() function returns the first non-null value from a list of arguments. You can use this to set "Intentionally unanswered" as the fallback for any blank input.
Example Expression:
For each response field:
coalesce(body('Get_response_details')?['yourQuestionID'], 'Intentionally unanswered')
You can use this inside:
A "Compose" action (to reuse the result later)
A "Populate a Microsoft Word template" action (for dynamic Word fields)
Option 2: Inline Expression in Populate Word Template
If you're using the "Populate a Microsoft Word template" connector, use expressions directly in the input fields.
Example:
if(empty(body('Get_response_details')?['yourQuestionID']), 'Intentionally unanswered', body('Get_response_details')?['yourQuestionID'])
This checks if the response is empty and injects the placeholder text if so.
Tip for Managing Many Fields
Since you're dealing with 50 questions, consider using:
Variables or Compose Actions with dynamic naming
A consistent naming convention like q1_response, q2_response etc.
Reusing a formula like above for each without wrapping in Condition blocks
You can even create a helper flow that builds a dictionary of question/response pairs with defaults and then merges that into your Word template.