How to Set Combo Box Default Value in Power Apps?

Have you been looking for how to set the Power Apps combo box default value? If Yes, Then follow this complete tutorial!

This Power Apps tutorial will explain How to set the default value of the Power Apps combo box.

Also, you will learn how to set the Power Apps combo box with multiple default values, set the Power Apps combo box default to the current user, and set Power Apps combo box default value empty.

Set Combo Box Default Value in Power Apps

In this section, you will learn how to set a default value to a Power Apps combo box control using two different scenarios:

  1. Power Apps set the default value of the combo box manually.
  2. Set the Power Apps Combo box default value using a SharePoint list.

Power Apps set the Combo box default value manually

I will show you how to set a Power Apps combo box control default value manually.

Example,

I created a Power Apps Canvas app and then added a Combo box control that contains the “Product Names” [Which I added manually].

Next, Whenever the user opens or loads an app, the Power Apps combo box control will automatically display its default value as shown below:

Power Apps combo box default

Let me show you how to achieve this:

  • Open your Power Apps with respective Microsoft credentials.
  • Create a Power Apps Blank canvas app -> Insert a Combo box control -> Set its combo box property to:
Items = [ "Tablet", "Laptop", "SmartPhone", "Desktop"]

DefaultSelectedItems = ["Laptop"]
Power Apps combo box control default items
  • Save, Publish, and close the app. Then, reopen and preview the app. The combo box control value will be selected as “Laptop” by default.
Power Apps set combo box default value

This is how to manually set the Power Apps combo box control default value.

Set the Power Apps Combo box default value using a SharePoint list

Let me check to set a Power Apps combo box control default value using a SharePoint list.

Example,

I have a SharePoint list [Customer Details] that has various columns like:

Column NameData Type
User NameTitle
CountrySingle line of text
Subscription TypeChoice [“Premium,” “Basic,” “Standard”]
DeviceChoice[“Laptop,” “Tablet,” “Smart TV,” “Smart Phone”
Subscription End DateDate and time
Subscription Handled ByPerson or group
How to set combo box default value in Power Apps

I created a Power Apps Canvas app and added a Combo box control connected to the above SharePoint list column [Country].

Next, the Power Apps combo box control will automatically display its default value as “US” whenever the user opens or loads an app.

How to set Power Apps combo box default value

Let me show you how to achieve this:

Power Apps set combo box default items
  • On the Power Apps screen, insert a Combo box control -> Set its combo box property to:
Items = Distinct('Customer Details',Country)

DefaultSelectedItems = ["US"]

Where,

  1. Customer Details = SharePoint list name
  2. Country = SharePoint list column name
  3. US = SharePoint list column value
Combo box default value in Power Apps
  • Save, Publish, and close the app. Then, reopen and preview the app. The combo box control value will be selected as “US” by default.
How to set combo box default items in Power Apps

This is how to set the Power Apps combo box default value using the SharePoint list.

Power Apps Combo box with multiple default values

I will show you how to set a default multiple values to a Power Apps combo box control.

Example,

  • I will take the above example of the Power Apps combo box control, setting multiple items as the default selected items.
  • I want to set “US” and “Germany” as default items.
Power Apps Combo box set multiple default values

Let me show you how to achieve this:

  • Select a Combo box control -> Set the combo box DefaultSelectedItems properties to:
["US", "Germany"]
How to set a default multiple values to a Power Apps combo box
  • Save, Publish, and close the app. Then, reopen and preview the app. The combo box control value will be selected as “US” and “Germany” by default.
Power Apps set combo box multiple default values.

This is how to set the multiple default values in the Power Apps combo box control.

Set the Power Apps Combo box default value to the current user

This section will explain how to set the Power Apps combo box default value as the current user.

Example,

I have added an Edit form connected to the SharePoint list [Customer Details]. The form contains the Combo box control (Subscription Handled By) connected to the above SharePoint list person column.

The Power Apps combo box control automatically displays the current user name when a user opens or loads an app.

Set the Power Apps combo box default to the current user

Follow the below steps to achieve it:

  • In Power Apps, connect the data source to the Office365Users as shown in the below image:
Power Apps combo box default to the current user
  • Select the Person Combo box control -> Set its DefaultSelectedItems property to:
{
    DisplayName: User().FullName,
    Claims: "i:0#.f|membership|" & Office365Users.MyProfile().UserPrincipalName
}
Power Apps set combo box default to the current user
  • Save, Publish, and close the app. Then, reopen and preview the app. The person combo box control value will be selected as a current user, as shown below:
Set combo box default to the current user in Power Apps

This is how to set the Power Apps combo box default to the current user.

Power Apps Combo Box Default Value Empty

This section will show you how to set a combo box default value as empty.

Example:

I created a Power Apps Canvas app and added a Combo box and Gallery control. The combo box control contains the values from the above SharePoint list column [Country].

Whenever the user opens or loads the app, by default, the combo box value should be selected as a blank value, and at the same time, the gallery should filter and display all the records.

Power Apps set combo box default to empty

Follow the below steps to achieve it:

  • On the Power Apps screen, insert Combo box control -> Set these below two properties of the combo box:
Items = Distinct('Customer Details',Country)

DefaultSelectedItems = Blank()

Where,

  1. Customer Details = SharePoint list name
  2. Country = SharePoint list column name
Set Power Apps combo box default value to empty
  • Insert Gallery control -> Set its Items property to:
If(
    cmb_Country.Selected.Value = Blank(),
    'Customer Details',
    Filter(
        'Customer Details',
        Country = cmb_Country.Selected.Value
    )
)

Where,

  1. cmb_Country = Combo box control name
  2. Customer Details = SharePoint list name
  3. Country = SharePoint list column name
How to set Power Apps combo box default to empty

You can see here I have set the combo box default value to empty in Power Apps.

Power Apps set combo box default value as empty

This is how to set the Power Apps combo box default value as empty.

Conclusion

By following our Power Apps tutorial, I hope your requirement has been fulfilled by setting a Power Apps combo box default value.

Also, from our tutorial, you have an idea for setting a Power Apps combo box with multiple default values, how to set the Power Apps Combo box default to the current user, and set Power Apps combo box default value as empty.

You may also like: