Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Building Power Apps
Answered

Combo Box not clearing properly

(0) ShareShare
ReportReport
Posted on by 72

I have a pair of combo boxes set up as filters for a gallery, one to choose a person, and one to choose a month.

The filters work fine for the most part, however if you select an item from the combo box, then re-open it and click the x to remove the selected item, the filters stop working. 

I have statements in the filtering formula so that if either is blank, it doesn't use it for the filtering so it's not the formula. I also have a button next to the combo boxes that just resets them both and that works properly and shows all items. So it seems when a user removes the item from the combo box, it does count the combobox.selected value as blank even though these is no selected item.

 

Any workarounds or settings I've missed?

  • Alchemy Profile Picture
    41 on at
    Re: Combo Box not clearing properly

    Thank you, you solved my problem as well! I had to change my formula in a few places from cmb_Filterstatus.SelectedItems, to cmb_Filterstatus.Selected.Value. I'll read up on why exactly!

  • Michael Seerup Profile Picture
    170 on at
    Re: Combo Box not clearing properly

    Fixed my issue as well. TY

  • crdawson Profile Picture
    72 on at
    Re: Combo Box not clearing properly

    That's done it, thanks!

  • Verified answer
    SebS Profile Picture
    4,146 Super User 2025 Season 1 on at
    Re: Combo Box not clearing properly

    @crdawson 

     

    I think it's not enough to just place AgentInput_1 you need to check Property so in that case IsBlank(AgentInput_1.Selected.Value) same for empty and that need to be done to all controls you try verifying cause you are checking if there is something in selection 

  • crdawson Profile Picture
    72 on at
    Re: Combo Box not clearing properly

    Thanks for the suggestion, I tried adding the IsEmpty() to the formula but it still functions the same. It functions perfectly if I click the "Clear" button I set up, but if you click the x in the combo box it breaks

    crdawson_0-1669822651114.png

     

    Here's the code:


    If(
    //If Agent filter is Blank
    Or(IsBlank(AgentInput_1), IsEmpty(AgentInput_1)),
    //Then check if month input is blank and if so show all items
    If(
    Or(IsBlank(MonthInput), IsEmpty(MonthInput)),
    Sort(
    Distinct(
    _EvaluatorRecords,
    Date(
    Year('Session Date'),
    Month('Session Date'),
    1
    )
    ),
    Result,
    Descending
    ),
    //Else, filter the results by the Month filter
    Sort(
    Filter(
    Distinct(
    _EvaluatorRecords,
    Date(
    Year('Session Date'),
    Month('Session Date'),
    1
    )
    ),
    Result = MonthInput.Selected.Value
    ),
    Result,
    Descending
    )
    ),
    //Else agent filter is not blank, check if month input is blank
    If(
    Or(IsBlank(MonthInput), IsEmpty(MonthInput)),
    //If month filter is blank, filter by only agent filter
    Sort(
    Distinct(
    Filter(
    _EvaluatorRecords,
    AgentInput_1.Selected.Result in Agent.Email
    ),
    Date(
    Year('Session Date'),
    Month('Session Date'),
    1
    )
    ),
    Result,
    Descending
    ),
    //Else, filter by both Month filter and Agent Filter
    Sort(
    Filter(
    Distinct(
    Filter(
    _EvaluatorRecords,
    AgentInput_1.Selected.Result in Agent.Email
    ),
    Date(
    Year('Session Date'),
    Month('Session Date'),
    1
    )
    ),
    Result = MonthInput.Selected.Value
    ),
    Result,
    Descending
    )
    )
    )

  • SebS Profile Picture
    4,146 Super User 2025 Season 1 on at
    Re: Combo Box not clearing properly

    @crdawson 

     

    try to add to the filleter on top of IsBlank() IsEmpty() and check if that will work or show the code from filter to verified if all is ok with it.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,651 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,999 Most Valuable Professional

Leaderboard