cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Lmcginnis
Level: Powered On

Label from Excel to display if none

Hi,

Is there a way to Display a value when there is an empty table? in this type of useage,

 

Concat(ComboBox1_1.SelectedItems,"Contact" &"-"&Contact&'Main Number'&'Alt Number' )

 

So if there is not a Contact, Main, or Alt Number, is there a way to display something like, xxx or xxx-xxx-xxx ?
 
Thanks,
1 ACCEPTED SOLUTION

Accepted Solutions
Lmcginnis
Level: Powered On

Re: Label from Excel to display if none

HI,

I think I got it to work, when I noticed I wasnt using the & function to call the "if" function, but then it was always displaying the "xxx-xxx-xxxx" .. so I tried this "!IsBlank" and it worked

Concat(ComboBox1_1.SelectedItems, 'ER Phone') & If(!IsBlank(ComboBox1_1.Selected. 'ER Phone'),"","XXX-XXX-XXXX")

4 REPLIES 4
Super User
Super User

Re: Label from Excel to display if none

Hi @Lmcginnis 

You can use the Coalesce function to do this:

Coalesce(Concat(ComboBox1_1.SelectedItems,
"Contact" &"-"& Contact &'Main Number' &'Alt Number'
),
"xxx-xxx-xxx"
)
Community Support Team
Community Support Team

Re: Label from Excel to display if none

Hi @Lmcginnis ,

Do you want to display a string as the format of “xxx-xxx-xxx” when one of the fields having a null value?

I’ve made a similar test, you could refer this:

Concat(ComboBox2.SelectedItems,

                                                               "Contact"&

                                                               If(IsBlank(ComboBox2.Selected. Contact),"","-"& Contact)&

                                                               If(IsBlank(ComboBox2.Selected. 'Main Number'),"","-"& 'Main Number')&

                                                               If(IsBlank(ComboBox2.Selected. 'Alt Number'),"","-"& 'Alt Number')

             )

 

 

 

Best regards,

Community Support Team _ Phoebe Liu

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Lmcginnis
Level: Powered On

Re: Label from Excel to display if none

Hi,

Can seem to edit you suggestion to work for my needs.

 

But yes, if the excel field is blank (a phone number) I would like it to display "XXX-XXX-XXXX" .

 

my current lable is formatted as,

Concat(ComboBox1_1.SelectedItems, 'ER Phone')

 

and I have tried, 

Concat(ComboBox1_1.SelectedItems, 'ER Phone')If(IsBlank(ComboBox1_1.Selected. 'ER Phone'),"","-XXX-XXX-XXXX")

 

It doesnt appear to work for me.

Thanks,

Lmcginnis
Level: Powered On

Re: Label from Excel to display if none

HI,

I think I got it to work, when I noticed I wasnt using the & function to call the "if" function, but then it was always displaying the "xxx-xxx-xxxx" .. so I tried this "!IsBlank" and it worked

Concat(ComboBox1_1.SelectedItems, 'ER Phone') & If(!IsBlank(ComboBox1_1.Selected. 'ER Phone'),"","XXX-XXX-XXXX")

Helpful resources

Announcements
firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

SecondImage

PowerApps Monthly Community Call

Next Wednesday, August 21st at 8am PDT

Top Community Contributors for July 2019

Top Community Contributors for July 2019

Let's thank our top community contributors

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

FirstImage

Power Platform World Tour

Coming to a city near you

thirdimage

PowerApps Community User Group Member Badge

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

FourthImage

Join PowerApps User Group!!

Connect, share, and learn with your peers year-round

FifthImage

Dynamics 365 and Power Platform April 2019 Release notes

Features releasing from April 2019 through September 2019!

SixthImage

Power Summit Australia 2019

August 20-23rd 2019

Users Online
Currently online: 181 members 3,593 guests
Please welcome our newest community members: