cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
cwebb365
Level 10

Set Default Selected Value of DropDown

You would think this would be simple as setting the default value to an ID of the drop down but aparently it's not that easy. 

 

Anyone know how I can set the default value that shows in the drop down or basically the selected Item on the dropdown control. It always shows the first value no matter what and the only way I can get it to show the value is using Filter, which does no good when you go to change the value. 

 

Is there a special value you have to pass into Default other than primary key value for it to know which record to use? 

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: Set Default Selected Value of DropDown

@cwebb365 

Yes, for a DropDown, the Default must be the same as the field that you are displaying in the dropdown.

So, if you are displaying Name in the DropDown, then you set the default to whatever text value you want for that field.  In your case, you're looking up the value and assigning name to the default...all is good.

 

By the way, the DropDown retains the fields of the record,  so elsewhere, you can get to the DropDown.Selected.ID or any other field in the record.

 

Glad you resolved it.

_____________________________________________________________________________________
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.

View solution in original post

2 REPLIES 2
cwebb365
Level 10

Re: Set Default Selected Value of DropDown

Solved it, Default property needs set to Lookup(datasource,ID = ThisItem.ID,Name) 

Was missing the ,Name part which is what is showing in the Dropdown field. 

Super User
Super User

Re: Set Default Selected Value of DropDown

@cwebb365 

Yes, for a DropDown, the Default must be the same as the field that you are displaying in the dropdown.

So, if you are displaying Name in the DropDown, then you set the default to whatever text value you want for that field.  In your case, you're looking up the value and assigning name to the default...all is good.

 

By the way, the DropDown retains the fields of the record,  so elsewhere, you can get to the DropDown.Selected.ID or any other field in the record.

 

Glad you resolved it.

_____________________________________________________________________________________
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.

View solution in original post

Helpful resources

Announcements
firstImage

Microsoft Business Applications Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

FirstImage

Power Platform World Tour

Coming to a city near you

thirdimage

PowerApps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

FourthImage

Join PowerApps User Group!!

Connect, share, and learn with your peers year-round

Top Kudoed Authors
Users Online
Currently online: 315 members 4,676 guests
Recent signins:
Please welcome our newest community members: