cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Gorilla_8
Post Prodigy
Post Prodigy

HOW TO NOT SHOW A SPECIFIC DATA INSIDE A HTML TEXT WHEN IS BLANK...

Hey guys, I need to not show data when a row is blank inside an HTML text...

 

 

Like this: 

 

IFISBLANKHTML.png

<td style='width: 213px;'>" &  "$ " & If(IsBlank("-";'Resumo Transporte Total')) &"</td>

 

1 ACCEPTED SOLUTION

Accepted Solutions

@Gorilla_8 

Same thing:

"<tr>" & 
  Concat(MasterGalleryHTMLDADOS.AllItems; 
    If(IsBlank('Resumo Transporte Total'), "", 
       "<td style='color:#61033A;'> RESUMO TRANSPORTE </td>
       <td style='width: 213px;'>" & Text('Resumo Transporte Total'; "[$-pt-BR] $ #,00")) &
       "</td>"
       )
    )
 &
"</tr>"

 

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

View solution in original post

34 REPLIES 34
RandyHayes
Super User
Super User

@Gorilla_8 

 

Try to change your formula to the following:

... "$ " & Coalesce('Resumo Transporte Total'; "-") & "</td>" ...

 

I hope this is helpful for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

@RandyHayes Thanks for the reply! 

 

But the PowerApps says "The 'Coalesce' function has some invalid arguments"

 

 

@Gorilla_8 

Which argument is it complaining about?  You can put your pointer over each for more detailed information.

 

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

All the function

@Gorilla_8 

It should give more specifics on the issue, but anyway...

 

What is 'Resumo Transporte Total'?

What context is this Html control in?  A gallery, a Screen, a Form?

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

A gallery data...

 

IFISBLANKHTML.png

@Gorilla_8 

If 'Resumo Transporte Total' is in AllItems of the Gallery and it is a text field, then the formula provided - Coalesce('Resumo Transporte Total', "-")  - should work just fine.

If you take all the logic out and just put 'Resumo Transporte Total' in your Concat function/Html builder, do you get the results?  (i.e. take out your original If function and my Coalesce function and just put the field name in)

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

Yes, I get the item on HTML editor, but I wanna show a "-" if is blank or not show the field.

 

 

@Gorilla_8 

Yep, Coalesce will do the trick.

Are we having a comma vs semicolon issue?  I was reviewing your original posting and noticed you are using semicolon separation in your formulas...If that is the case, then my formula to you should have been:

Coalesce('Resumo Transporte Total'; "-")

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

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.

Top Solution Authors
Top Kudoed Authors
Users online (2,536)