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 / TextBox Fill Changing ...
Power Apps
Unanswered

TextBox Fill Changing Unexpectedly

(0) ShareShare
ReportReport
Posted on by 54

Hello,

I have an app with a gallery of 39 questions. The expected behavior is for the Fill of the question TextBox to change based on the selected value of a Radio Button.

 

The issue, when I test, for the first few questions I answer, it works great (green for pass, red for fail) as you can see in my first picture.

picture1.JPG

In the second picture you can see how some of the questions start to turn green even without me selecting anything from the Radio Buttons (question 7).

picture2.JPG

I've tested this out in the following ways:

  • Chrome
  • Edge
  • Clearing the browser cache
  • Windows PowerApps Desktop
  • iPhone
  • PowerApps Studio

All of my testing results in the same issue. I can't seem to find a consistant pattern of the issue either. sometimes it starts to behave weird after 5 questions, of sometimes after 10 questions. Green or Red, it doesn't matter.

 

I thought this behavior was very weird and was hoping that someone has had a simular issue and resolution. Maybe I'm doing something wrong all together.

 

Thank you in advance to anyone who can shed some light or guidence on this.

 

- Justin

Categories:
I have the same question (0)
  • panand99 Profile Picture
    641 on at

    @Justair07 

    I think there are multiple Radio fields and you passed the refrence of only first field which has the name of ARadio.

     

    Please check.

  • Justair07 Profile Picture
    54 on at

    Hi @panand99,

     

    I have only one radio field but it is in a gallery. I'm beginning to think that this is a PowerApp limitation. 😞

  • Luke_Timmins Profile Picture
    176 on at
    The screenshot with all green boxes looks a bit odd. Why is the selection box not lined up with the green box?

    Thanks
    Luke
  • Luke_Timmins Profile Picture
    176 on at
    I realised it was a gallery and it's the initial question box location.

    Have you got a default value set in the radio control? Is the control linked to a data column?
  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Update:

    With the help of @faustocapellanj , we were able to come up with a solution to achieve the desired effect.

     

    We created a collection that stored the unique ID of each item in the gallery and also stored the result from the radio box. There is an IF statement to first determine if the radio button has already been changed, if it has, when it is changed again, Patch the new result to the collection, if not, simply store the ID and result in the collection. Here is the code for the OnChange feature for the radio button:

    If(IsBlank(LookUp(colRadio,QuestionId=ThisItem.IdQuestion)),
     Collect(colRadio,
     {
     QuestionId:ThisItem.IdQuestion,
     PassFail:ARadio.Selected.Value
     }
     ),
     Patch(colRadio,
     {
     QuestionId:ThisItem.IdQuestion
     },
     {
     PassFail:ARadio.Selected.Value
     }
     )
    )

     and here is the code for changing the Fill on the label:

    If(
     LookUp(
     colRadio,
     QuestionId = ThisItem.IdQuestion,
     PassFail
     ) = "Pass",
     RGBA(0,230,64,.7
     ),
     LookUp(
     colRadio,
     QuestionId = ThisItem.IdQuestion,
     PassFail
     ) = "Fail",
     RGBA(207,0,15,.8),
     RGBA(0,0,0,0)
    )

    Don't forget to clear the collection upon exiting the app.

    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

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 329 Most Valuable Professional

#2
11manish Profile Picture

11manish 209 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 179

Last 30 days Overall leaderboard