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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Changing combo box fil...
Power Apps
Answered

Changing combo box fill color based on DisplayMode

(0) ShareShare
ReportReport
Posted on by 49

Hi, 

I want to change the fill color of a combo box depending on the current displayMode. I wrote this code: 
If( ddComboBox.DisplayMode = DisplayMode.Edit, RGBA(255, 255, 255, 1) , RGBA(217, 216, 216, 1))

But even though the display mode is now set to edit, fill is in the color RGBA(217, 216, 216, 1).

How can I solve this? 

Categories:
  • Verified answer
    OdinDelToro Profile Picture
    407 on at

    Hello @MKPA,

     

    Please try using Self instead of the combobox name as long as the fill is for the same combobox.

    If(Self.DisplayMode = DisplayMode.Edit,RGBA(255,255,255,1),RGBA(217,216,216,1)) 

     

    Hope this helps clarify the doubt, let me know in case you're still facing an issue within it.

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

  • MKPA Profile Picture
    49 on at

    Worked like a charm... 🙂 Thank you!

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 236 Super User 2026 Season 2

#2
WarrenBelz Profile Picture

WarrenBelz 207 Most Valuable Professional

#3
Mohsin Ali Profile Picture

Mohsin Ali 169

Last 30 days Overall leaderboard