web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / ComboBox resets after ...
Power Apps
Answered

ComboBox resets after the patch function is used

(0) ShareShare
ReportReport
Posted on by 894

Reading through old posts about how to prevent a combobox from resetting. There is no ClearCollect function on the app...

I'd really like to keep showing the selected item after I hit the Save button. (Data is connected to Dataverse)

Skärmavbild 2021-12-15 kl. 11.02.48.png

Skärmavbild 2021-12-15 kl. 10.17.07.png

Multiple choices not allowed and the combo box is showing records from a Project table.

The Default is expecting a Record and using MySelection only in that property gives errors.

In the OnSelect property It worked to add Set(MySelected, ComboBoxProject.Selected) - though adding a .Value or .Result is giving errors.

(Been trying options presented in other threads.)

Categories:
I have the same question (0)
  • AJ_Z Profile Picture
    3,711 Super User 2024 Season 1 on at

    did you try instead of MySelection try [MySelection]

  • Gyllentid Profile Picture
    894 on at

    Should it be within brackets? I will try.

  • AJ_Z Profile Picture
    3,711 Super User 2024 Season 1 on at

    Give it a try it may just need to be wrapped in some square brackets [] let me know how that goes

    if my comments are helpful be sure to Like/Kudo them and if it is your solution please click accept as solution

     

  • Gyllentid Profile Picture
    894 on at

    @AJ_Z 

    It seems quite unhappy and expecting a record. 

    Skärmavbild 2021-12-15 kl. 11.47.40.png

  • AJ_Z Profile Picture
    3,711 Super User 2024 Season 1 on at

    try put it in defaultselecteditems instead try with brackets and without brackets

    if my comments are helpful be sure to Like/Kudo them and if it is your solution please click accept as solution

  • AJ_Z Profile Picture
    3,711 Super User 2024 Season 1 on at

    even though its not multi select put it in default selected items instead of default lets see what happens

  • Verified answer
    Gyllentid Profile Picture
    894 on at

    I wondered about that too, in the other threads posters said it should be in the Default property so I followed that. However, I was just listening to Shane Youngs video about it and he said it should be in DefualtItemsProperty.

     

    In that DefaultItemsProperty it worked to do a filter: 
    Filter('Project Divisions', Name = Gallery1participant_1.Selected.Project.Name)

     

    Thanks for the help!

  • AJ_Z Profile Picture
    3,711 Super User 2024 Season 1 on at

    Happy to have been of help so did the MySelected.Name or MySelected not work in default selecteditems

  • Gyllentid Profile Picture
    894 on at

    Hi @AJ_Z Unfortunately, both gave errors. Though I might be missing something there...

  • AJ_Z Profile Picture
    3,711 Super User 2024 Season 1 on at

    Okay well i am glad to here it is working now 🙂

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 600

#2
WarrenBelz Profile Picture

WarrenBelz 478 Most Valuable Professional

#3
Valantis Profile Picture

Valantis 322

Last 30 days Overall leaderboard