cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
DanielaHo
Advocate IV
Advocate IV

Gallery dropdown selection & patch glitch

Hi,

I followed Shane's video (A better PowerApps Data Model) to create a questionnaire, for each question users should select likelihood and impact. OnChange their response is patched to a collection.

Having just 1 dropdown works fine, but having 2 causes glitchy behavior (while using Radio buttons works as expected):

When I make a selection in one dropdown, the other pre-populates (but without patching it to the collection).

Can anyone reproduce shane’s example with 2 dropdowns?

 @Shanescows ?

 

Capture.JPG

Gallery Properties:

  • Items: Coll_Responses 

Dropdown 1 Properties:

  • Default: ThisItem.Likelihood
  • Items: ["","unlikely", "likely", "very likely"]
  • OnChange: Patch(Coll_Responses, ThisItem, {Likelihood: Dropdown1.Selected.Value})

Dropdown 2 Properties:

  • Default: ThisItem.Impact
  • Items: ["","low", "med", "high"]
  • OnChange: Patch(Coll_Responses, ThisItem, {Impact: Dropdown2.Selected.Value})
1 ACCEPTED SOLUTION

Accepted Solutions

Actually... using UpdateIf instead seems to fix the problem: 

UpdateIf(Coll_Responses, QuestionID = ThisItem.QuestionID, {Likelihood: Dropdown1.Selected.Value})

View solution in original post

5 REPLIES 5
DanielaHo
Advocate IV
Advocate IV

Anyone? 🙏

Hi @DanielaHo 

I'm guessing but it looks like by using OnChange property for the dropdowns, only one is actually being patched because the other is not physically changed.  As a suggestion, take out the Patch() function in the OnChange and put an icon in the gallery and set it's OnSelect to patch both Dropdowns.

 

Patch(
       Coll_Responses, ThisItem, 
         {Likelihood: Dropdown1.Selected.Value,
          Impact:Dropdown2.Selected.Value
          }
)

 

 

Hi   

Thanks for the suggestion. However, strangely I still get the described behavior - although now only for some items not all - where you select one dropdown value and it populates the other upon patching. 

🤔😕So strange... ?!

Actually... using UpdateIf instead seems to fix the problem: 

UpdateIf(Coll_Responses, QuestionID = ThisItem.QuestionID, {Likelihood: Dropdown1.Selected.Value})

RambabuVakadan
Regular Visitor

are able to solve this ?

Helpful resources

Announcements
Power Platform Call June 2022 768x460.png

Power Platform Community Call

Join us for the next call on August 17, 2022 at 8am PDT.

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.

Users online (1,678)