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

Dropdown list default blank, when using a SQL Table as DataSource.

Hi Community. 

I have a problem, 
When I add data into a dropdown list it default starts with the first value in the column. 
I have seen different solutions when using sharepoint as datasource, but I use SQL tables as source. 

Br. Tore

1 ACCEPTED SOLUTION

Accepted Solutions
Resolver I
Resolver I

@ToreG ,

You could add your SQL table to a collection then create a blank row in order to default on e.g.

 

ClearCollect(colExample, {Field: ""}); Collect(colExample, <yourSQLtable>)

Then on your dropdown, set the items to colExample and the default to "1" to select the blank record.

View solution in original post

6 REPLIES 6
Dual Super User II
Dual Super User II

Hi @ToreG 

 

Yes, by default this selects the first item in the dropdown items, if you wish to set this to other item, then you can set the "default" value of the dropdown control.
 
If you need help with constructing the formula for it, please share the logical implementation so that we may help you better.
 
Hope this Helps!
 
If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Hej Yashag2255. 

But if the default value is set to "" and the dropdown is still showing the first value in the column. 

I have column A with 20 values, and i dont want it to show any values before the user pick one from the dropdown. 


Dual Super User II
Dual Super User II

Hi @ToreG 

 

That is the default configuration of the dropdown control to select the first item if default is not set.
 
If you wish to keep the selection as empty, you can create a combobox control instead of dropdown, use the same items in the combobox control and disable "Allow Searching" if you do not wish to search through the items.
 
Hope this Helps!
 
If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Hi @ToreG 

If you want to use the DropDown control rather than the ComboBox control, a possible workaround would be to use a SQL View. In the View, you would UNION a row with an empty string to provide your blank option. Post back here if you need more details.

Resolver I
Resolver I

@ToreG ,

You could add your SQL table to a collection then create a blank row in order to default on e.g.

 

ClearCollect(colExample, {Field: ""}); Collect(colExample, <yourSQLtable>)

Then on your dropdown, set the items to colExample and the default to "1" to select the blank record.

View solution in original post

Thanks Ajennings1. 

 

Helpful resources

Announcements
New Badges

New Solution Badges!

Check out our new profile badges recognizing authored solutions!

New Power Super Users

Congratulations!

We are excited to announce the Power Apps Super Users!

Power Apps Community Call

Power Apps Community Call: February

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

Microsoft Ignite

Microsoft Ignite

Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!

Top Solution Authors
Top Kudoed Authors
Users online (34,757)