cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
SectorOMEGA
Helper V
Helper V

Color changing based on content

I have a simple power app for user registration. Behind it I have a simple power automate to send HTML formatted messages:

PA Covid.PNG

What Im trying to achieve is change the color of the input of 'Employee Last Site Visit' to be based on the 'Date' column.

For example if 'Employee Last Site Visit' is 3 days smaller than 'Date' column, than Input to be in red color.
Is this even possible? Thank you in advance.

1 ACCEPTED SOLUTION

Accepted Solutions
RezaDorrani
Dual Super User II
Dual Super User II

Hi @SectorOMEGA 

 

Check https://www.youtube.com/watch?v=VnWg-Eox37Q

 

--------------------------------------------------------------------------------
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.

Thanks,
Reza Dorrani, MVP
YouTube
Twitter

View solution in original post

3 REPLIES 3
RezaDorrani
Dual Super User II
Dual Super User II

Hi @SectorOMEGA 

 

Check https://www.youtube.com/watch?v=VnWg-Eox37Q

 

--------------------------------------------------------------------------------
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.

Thanks,
Reza Dorrani, MVP
YouTube
Twitter

Hi @RezaDorrani  THANK YOU so much for this one. Really useful and nice video. However when I recreate it with the expressions form it I receive this:

2021-10-05

2021-08-01

<font color = "green">Closed</font>

2021-10-05

2021-07-01

<font color = "red">Open</font>

For the color expression Im using this code:

if(equals(item()?['CaseStatus/Value'],'Open'),'red',if(equals(item()?['CaseStatus/Value'],'Closed'),'green','black'))

As per the above return the code works because it changes the status but Im not getting color rather getting the code back with the true/false statement. What Im missing?

SectorOMEGA
Helper V
Helper V

@RezaDorrani Fixed. I was missing ' in the clean HTML step. I have added it and all is working good. Thank you so much Reza

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Power Automate Designer Feedback_carousel.jpg

Help make Flow Design easier

Are you new to designing flows? What is your biggest struggle with Power Automate Designer? Help us make it more user friendly!

Top Solution Authors
Users online (1,866)