cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Advocate I
Advocate I

Deleting Combo Box Selected Item to Filter Gallery makes my app crash

Hello Power Apps Community,

 

This it my first encounter of something very weird happening when making application in power apps.

So I have this scenario which should be very simple and working every time.

But since yesterday it becomes undeniably weird.

 

These are brief description about my problem :

 

  1. I have a combo box which contain items from predefined table
  2. I have gallery that contain the same items from the same table
  3. I use the combo box to filter the item in the gallery based on its certain column
  4. Every time I select new item OR changing it to another item, the gallery shows the correct item and working fine
  5. But when I DELETE that selected item in the combo box, then my editor screen went blank.
  6. If I play the app, then somehow it shows the spinner and reload it again

I post some pictures here, and also gif files so the problem can be clear here.

 

Selection_!Selection_!

 

Selection_2Selection_2

 

4.jpg

 2020-11-05_07-55-13.gif

 

The working solution for now, I have to use Collection for the gallery to be able to filter it using combo box.

 

Is this some problem with the power apps right now?
Because my already published app also facing this problem.

I hope you guys here can help me.

 

Best regards,

Rizky - Indonesia

1 ACCEPTED SOLUTION

Accepted Solutions
Power Apps
Power Apps
5 REPLIES 5
Community Support
Community Support

Hi@rizkyaditya,

Based on the issue that you mentioned, do you mean that the Gallery displays nothing when you clear the selected item within the Combo Box?

Could you please share a bit more about the scenario, do you want the Gallery to display all the items when there is nothing within the Combo Box?

I have a test to reproduce your issue and the situation is confirmed on my side. I want to let you know that this is a normal situation rather than a crash.

combo1.pngcombo2.png

From the above screenshot, you could see that the Gallery does display nothing when you clear the Combo Box selected.

The key to the problem is how you set the Items property of the Gallery. If you want to filter the Gallery based on the Combo Box selected using a similar formula as below, the Gallery certainly doesn't filter out any records for you even don't provide a filter condition.

I set the Items property of the Gallery as below:

 

Filter(FRR,Title=ComboBox1.Selected.Result)

 

If you want to display all the records from the data source when there is none selected within the Combo Box, you could write the following formula to the Items property of your Gallery:

 

If(
    IsBlank(ComboBox1.Selected),
    Filter(
        FRR,
        StartsWith(
            Title,
            TextSearchBox1.Text
        )
    ),
    Filter(
        FRR,
        Title = ComboBox1.Selected.Result
    )
)

 

Note: 'FRR' is an SP list as my data source, 'Title' is a Text column I choose to filter the Gallery based on the Combo Box1 selected. TextSearchBox1 is a TextInput control I used to filter the Gallery based on the search text related to the 'Title' column.

combo3.png

Hope it could help.

Best Regards,

Qi

Hello @v-qiaqi-msft 

Based on the issue that you mentioned, do you mean that the Gallery displays nothing when you clear the selected item within the Combo Box?

 

No Sir.

This is not what I mean.

I am clear myself to distinguish between empty gallery because of some filtering and weird event that happened to me. 

 

You can try your self here.
This is my trial table for the combo box data source.

Table(
{Title: "Test 1", Content: "This is test 1"},
{Title: "Test 2", Content: "This is test 2"},
{Title: "Test 3", Content: "This is test 3"},
{Title: "Test 4", Content: "This is test 4"}
)

And this is my gallery items which is just the same table but filtered from the combo box

Filter(Table(
{Title: "Test 1", Content: "This is test 1"},
{Title: "Test 2", Content: "This is test 2"},
{Title: "Test 3", Content: "This is test 3"},
{Title: "Test 4", Content: "This is test 4"}
),Title = ComboBox1.Selected.Title)

 

You can find the anomaly in my first post.

I attached the gif file again just in case the file can not be opened correctly.

 

The problem just suddenly happened.

When I clear the combo box, the app become sort of crashed.

Community Support
Community Support

Hi@rizkyaditya,

I have a test on my side and the issue is confirmed on my side.

In the edit mode, when you clear all the selected items from the Combo Box, the PowerApps studio will be in a crash and it could not be fixed automatically for a short time. The situation currently is that the Combo Box and the Gallery disappear, the studio maker screen changes to grey.

In the play mode, when you clear all the selected items from the Combo Box, the app will be in crash for seconds and it could be fixed automatically for the first time. And when it got fixed, I repeat the previous operation, the App page got grey.

Currently, this problem has been reported to our support team. I will update this as soon as I get the response.

Best Regards,

Qi

Power Apps
Power Apps

Dear all readers,

 

Big thanks to @_Corey_  and his teams to address this problem in a quick way.

The answer is here : App Crash because Deleting Combo Box Selected Item to Filter Gallery 

 

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 (33,270)