web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Office365Users Account...
Power Apps
Unanswered

Office365Users AccountEnabled value color

(0) ShareShare
ReportReport
Posted on by 83

Hi Community

 

for 

ThisItem.AccountEnabled I would like value Color
true = Green
false = Red
 
i ahev tried
 
If(ThisItem.AccountEnabled.Value = "true", Green, ThisItem.AccountEnabled.Value = "false", Red)
i have also trued
If(ThisItem.AccountEnabled = "true", Green, ThisItem.AccountEnabled= "false", Red)
and using my text label
If(UserAccountEnabled.Text = "true", Green, UserAccountEnabled.Text = "false", Red)
 
all do not work, not sure where i am going wrong
Categories:
I have the same question (0)
  • SpongYe Profile Picture
    5,603 Super User 2025 Season 2 on at

    Hi @uwtsd-shind 

     

    Try this:

     

    If(ThisItem.AccountEnabled, Green, Red)

     

     

    -----------------------
    PowerYsa Power Platform Enthusiast [LinkedIn] | [Youtube]

    I love to share my knowledge and learn from others. If you find my posts helpful, please give them a thumbs up 👍 or mark them as a solution ✔️. You can also check out my [@PowerYSA] for some cool solutions and insights. Feel free to connect with me on any of the platforms above. Cheers! 🍻

  • CU25021858-0 Profile Picture
    83 on at

    Hi @SpongYe 

     

    in Color = fx

    i put

    If(ThisItem.AccountEnabled, Green, Red)

     

    the error i get is

    the function "if" has come invalid arguments

  • Verified answer
    SpongYe Profile Picture
    5,603 Super User 2025 Season 2 on at

    Hi @uwtsd-shind 

     

    You need to add Color before Green and Red. 

    If(ThisItem.AccountEnabled, Color.Green, Color.Red)

     

    -----------------------
    PowerYsa Power Platform Enthusiast [LinkedIn] | [Youtube]

    I love to share my knowledge and learn from others. If you find my posts helpful, please give them a thumbs up 👍 or mark them as a solution ✔️. You can also check out my [@PowerYSA] for some cool solutions and insights. Feel free to connect with me on any of the platforms above. Cheers! 🍻

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 717 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 329 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard