Skip to content

La vie rêvée d'Akim

…ou le zèbre qui voulait être un homme

  • Style de vie
  • Informatique
  • Photographie
  • Musique
  • English (US)English (US)
  • FrançaisFrançais

Populate a Microsoft Power Apps drop down with a list of unique items, and no blank value

Posted on Friday 15 January 2021 - Friday 15 January 2021 by Akim

I’ve been struggling for a while, yet I sorted it out. Wooohooo.

The challenge

I’ve been trying to populate a drop down list in a Powerapp application. The source is a column called “Category” in an Excel document stored on OneDrive. The Category column contains redundant data and empty records. The drop down list has to be populated with single occurrence of categories and but not show an empty line. I want them the list to be alphabetically sorted.

The solution

It requires to encapsulate multiple functions. This is the function you have to put in your “Items” field for the drop down.

SortByColumns(Distinct(Table1,If(Not(IsBlank(Category)),Category)),"Result")

Table1 is my source table. Category is my source column (or field). Not(IsBlank(Category)) will collect the full list except blank records. Distinct will then remove duplicates from the list. Finally, SortByColumns will sort the results based on the Category field. By default, sorting will be ascending.

Here we are.

Partager :

  • Facebook
  • LinkedIn
  • More
  • Email
  • Print
  • Twitter

Sur le même thème

Posted in InformatiqueTagged Microsoft Power Apps

Post navigation

Shrewsoft VPN Client connection automated

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Subscribe to Blog via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Join 12 other subscribers

Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.
To find out more, including how to control cookies, see here: Cookie Policy
Proudly powered by WordPress | Theme: micro, developed by DevriX.
loading Cancel
Post was not sent - check your email addresses!
Email check failed, please try again
Sorry, your blog cannot share posts by email.