cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Vstar19
Post Patron
Post Patron

Power Automate to check for blank values in Excel Table

Hello, 

I have an excel template which contains First Name, Last Name, Managers Email Employee ID etc.  Users fill in this template and submit it via MS Forms.  Users can submit 100s of first name, last name, etc...

However, several users are submitting the form without populating their Employee ID and Managers Email etc.  For e.g. First Name have all the information  populated, whereas others don't. 

 

My aim is : If any value is empty, then send the template back to the submitter. 

 

I have started to write a flow which Lists rows present in a table then I added an apply to each which looks at the value of Lists Rows present in table and then I included a condition to say , as below

 

Flow Apply to eachFlow Apply to each

 

 

 

 

 

 

 

 

I now need to have the flow to say, if any of the values are blank, then send the template back to the submittor. 

 

I am just struggling on the bit where I have to get flow to send the template back if any of the values are blank.  At the moment, it loops through each value and there is an output for each value. But I need an output for the entire thing to say if just one value is empty, then send the template back. 

 

Hope that makes sense.  happy to reclarify if needed. 

 

Thanks. 

1 ACCEPTED SOLUTION

Accepted Solutions
mjburley
Resolver II
Resolver II

You can use the empty() function to check for a blank cell in Excel; I use the following to write to Sharepoint, writing in null when the Excel field is blank and the excel value if it is not blank.

 

if(empty(items('Apply_to_each')?['ExcelField']), null ,items('Apply_to_each')?['ExcelField'])
 
You should be able to use the first part in an Control statement using the expression editor.
 
i.e.
 
empty(items('Apply_to_each')?['ExcelField'])

View solution in original post

5 REPLIES 5
mobashee
Community Support
Community Support

Dear Partner,

The simplest way is to make the filed mandatory on MS forms so the fields will not be empty.

 

Regards,

Mohamed Sanuj Basheer

 

 

Hi Mobashee,

Thank you for your response. 

I think you have have misunderstood the question or my explanation was not clear. The user submits an Excel File and uploads that to MS forms. 

Thanks. 

mjburley
Resolver II
Resolver II

You can use the empty() function to check for a blank cell in Excel; I use the following to write to Sharepoint, writing in null when the Excel field is blank and the excel value if it is not blank.

 

if(empty(items('Apply_to_each')?['ExcelField']), null ,items('Apply_to_each')?['ExcelField'])
 
You should be able to use the first part in an Control statement using the expression editor.
 
i.e.
 
empty(items('Apply_to_each')?['ExcelField'])
JIden
Frequent Visitor

Where is this formula pasted? In the condition added in the flow or can dynamic expression be used to ignore blank entry? Thank you

 

Can you include screenshots of this in a flow?

Helpful resources

Announcements
Power Automate News & Announcements

Power Automate News & Announcements

Keep up to date with current events and community announcements in the Power Automate community.

Power Automate Community Blog

Power Automate Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Users online (3,926)