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 / Change Color of Form F...
Power Apps
Answered

Change Color of Form Field if it contains a word

(0) ShareShare
ReportReport
Posted on by 113

How can I change the background color of a form field (multiline text) if it contains a word?

 

Thanks!

Categories:
I have the same question (0)
  • WarrenBelz Profile Picture
    154,928 Most Valuable Professional on at

    Hi @LYNCHJL ,

    In the Fill of your Text control - substitute your word, control name and colour.

    If(
     "YourWord" in YourTextBoxName.Text,
     YourColour,
     White
    )

     note this will only show once the filed has been entered.

     

    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.

  • Verified answer
    eka24 Profile Picture
    20,925 on at

    Use:
    If(!IsBlank(Find("abc",Textboxl.Text)),Green,Blue))

    ------------

    If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

  • Verified answer
    v-xida-msft Profile Picture
    Microsoft Employee on at

    Hi @LYNCHJL ï¼Œ

    Based on the needs that you mentioned, I agree with @eka24 and @WarrenBelz 's thought almost. You could take a try with them to achieve your needs.

     

    As an another solution, I think the IsMatch function could achieve your needs. Please consider set the Fill property of the Text Input Box to following:

    4.JPG

     

    If(
     IsMatch(TextInputBox.Text, "Type Specific Word Here", MatchOptions.Contains), // Replace TextInputBox with actual control name in your Edit form
     Color.Red , // changed bg color
     RGBA(255, 255, 255, 1) // defualt background color
    )

     

     

    Please consider take a try with above solution, then check if the issue is solved.

     

    Best regards,

  • Verified answer
    WarrenBelz Profile Picture
    154,928 Most Valuable Professional on at

    Hi @LYNCHJL ,

    I have tested mine on a model and it works - I have no doubt the others will also (there are many ways of doing the same thing).

    Please tag whoever you want any further clarification from.

     

    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.

  • v-xida-msft Profile Picture
    Microsoft Employee on at

    Hi @LYNCHJL ,

    Have you taken a try with above solutions? Is it helpful in your scenario?

     

    If you have solved your problem, please consider go ahead to click "Accept as Solution" to identify this thread has been solved.

     

    Best regards,

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 551

#2
WarrenBelz Profile Picture

WarrenBelz 430 Most Valuable Professional

#3
Valantis Profile Picture

Valantis 298

Last 30 days Overall leaderboard