cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ericonline
Community Champion
Community Champion

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
Gristy
Resident Rockstar
Resident Rockstar

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

abm
Super User III
Super User III

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!

Learn more from my blogPower Automate Video Tutorials

View solution in original post

RezaDorrani
Dual Super User II
Dual Super User II

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
Gristy
Resident Rockstar
Resident Rockstar

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

abm
Super User III
Super User III

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!

Learn more from my blogPower Automate Video Tutorials

View solution in original post

RezaDorrani
Dual Super User II
Dual Super User II

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

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
MPA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

R2 (Green) 768 x 460px.png

Microsoft Dynamics 365 & Power Platform User Professionals

DynamicsCon is a FREE, 4 half-day virtual learning experience for 11,000+ Microsoft Business Application users and professionals.

Top Solution Authors
Users online (2,410)