cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Frequent Visitor

Allowed Values drop down defults to the first item

Hi,

 

Im new to PowerApps. Here is my issue:

 

I have a Number field (Confidence Factor) in a SPList connected to an Allowed Value data card in PowerApps.

 

Fonzcorp_0-1605285094377.png

 

This data card was switched to custom because I wanted the user to be able to input 3 Percentiles only. So i edited the "Items" field for it like so.

Fonzcorp_1-1605285224083.png

 

It works fine and when the user submits a change it changes in the SPList. The problem is that when they go back to edit the card by default it diplays the first Item (100%) rather than what was saved in the SPList.

 

Fonzcorp_2-1605285547008.png

EX: After changing it to 30% and saving it, on reloading and returning to the screen, the card will show 100% instead of 30%. Not sure what im missing here. Any help is apprceciated. Thanks.


1 ACCEPTED SOLUTION

Accepted Solutions
Super User III
Super User III

@Fonzcorp 

First, as you are learning PowerApps, you actually do not need to do this type of thing.  When you have an EditForm, you can click on the Edit fields in the properties of the EditForm and for the field (confidence factor in this case) choose the "..." menu and change the control type to "Allowed Values".  This will automatically put in a dropdown for you and wire all the logic to put the data in and out as needed.  Once you have done that, you can then unlock the data card and change the AllowedValues property to : ["100%", "70%", "30%"] and again, everything will be done.

 

Now, if you stay with trying to do this on your own, then you need to look at the Default property of your Dropdown.  It should be set to Parent.Default  and your Default property of the DataCard that the control is in needs to still be ThisItem.ConfidenceFactor (assuming that is the field name...adjust as needed).

 

I hope this is helpful for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too!

View solution in original post

2 REPLIES 2
Super User III
Super User III

@Fonzcorp 

First, as you are learning PowerApps, you actually do not need to do this type of thing.  When you have an EditForm, you can click on the Edit fields in the properties of the EditForm and for the field (confidence factor in this case) choose the "..." menu and change the control type to "Allowed Values".  This will automatically put in a dropdown for you and wire all the logic to put the data in and out as needed.  Once you have done that, you can then unlock the data card and change the AllowedValues property to : ["100%", "70%", "30%"] and again, everything will be done.

 

Now, if you stay with trying to do this on your own, then you need to look at the Default property of your Dropdown.  It should be set to Parent.Default  and your Default property of the DataCard that the control is in needs to still be ThisItem.ConfidenceFactor (assuming that is the field name...adjust as needed).

 

I hope this is helpful for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too!

View solution in original post

Frequent Visitor

Hi, 

If you created a custom drop down with the 3 values and then you clicked on a save button, you could try the following things to see if this works for you. 

Solution 1. Select the drop down and go to tab "advanced" > section "data" > Set "false" in the property "Reset" and try one more time. 
Solution 2. In case you are working with gallery control, please make sure you're doing the patch correctly with the unique identifier for that record. 

 

Hope this helps.

Regards, 
Wen Ying Peng. 

If this post helps, then please consider Accept it as the solution to help the other members find it.

Helpful resources

Announcements
secondImage

Experience what’s next for Power Apps

Join us for an in-depth look at the new Power Apps features and capabilities at the free Microsoft Business Applications Launch Event.

Power Apps Community Call

Power Apps Community Call: February

Did you miss the call? Check out the Power Apps Community Call here.

New Power Super Users

Congratulations!

We are excited to announce the Power Apps Super Users!

New Badges

New Solution Badges!

Check out our new profile badges recognizing authored solutions!

Top Solution Authors
Top Kudoed Authors
Users online (13,063)