cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Super User
Super User

How to determine if a string variable is blank?

How is this accomplished? Now that the advanced editor is missing from Conditions, I don't know how to check to see if a string is empty!

Previously I'd do something like @{empty(variables('varName'))} in the condition. 

image.png

3 ACCEPTED SOLUTIONS

Accepted Solutions
Super User
Super User

Re: How to determine if a string variable is blank?

you can use null in a express on the right side

 

or

 

use length(var) on the left is greater than 0.

View solution in original post

Super User
Super User

Re: How to determine if a string variable is blank?

Hi @ericonline 

 

Did you tried using the length expression?

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!



View solution in original post

Dual Super User
Dual Super User

Re: How to determine if a string variable is blank?

Hi @ericonline 

 

You can still use the old expression @{empty(variables('varName'))}

 

just this time becuase its being used in a  condition

 

Capture.PNG

 

--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.

 

View solution in original post

4 REPLIES 4
Super User
Super User

Re: How to determine if a string variable is blank?

you can use null in a express on the right side

 

or

 

use length(var) on the left is greater than 0.

View solution in original post

Super User
Super User

Re: How to determine if a string variable is blank?

Hi @ericonline 

 

Did you tried using the length expression?

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!



View solution in original post

Dual Super User
Dual Super User

Re: How to determine if a string variable is blank?

Hi @ericonline 

 

You can still use the old expression @{empty(variables('varName'))}

 

just this time becuase its being used in a  condition

 

Capture.PNG

 

--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.

 

View solution in original post

Super User
Super User

Re: How to determine if a string variable is blank?

I've tried @RezaDorrani 's solution and it worked. I'll mark all three of your suggestions as a solution as I'm sure they also work.

Thank you very much!

Helpful resources

Announcements
firstImage

Power Platform Online Conference

Speakers, submit your sessions now! Call for speakers ends Feb. 10!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

firstImage

Incoming: New and improved badges!

We've given our badges an overhaul and also added some brand new ones!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Solution Authors
Top Kudoed Authors (Last 30 Days)
Users online (5,130)