Hi everyone,
I was implementing the remove functionality from the gallery (data source as Excel file). I was referring the documentation section for remove() but was getting an warning:
The format for OnSelect for Delete button as per the format. I have used a flag varShowPopup to rest the flag to false as the next statement after remove to hide the pop-up box.
HI @Sidhant_02 ,
Assuming you have a unique identifier column in your record (replace with the field name)
RemoveIf( Contacts, IdentifierName = Gallery1.Selected.IdentifierName )
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.
MVP (Business Applications) Visit my blog Practical Power Apps
So the IdentifierName should be replaced with one of the columns from my Excel?How to make a column unique?
Why cannot we use only Remove to remove a record instead of RemoveIf where in we have to specify a condition?.
Hi @Sidhant_02
Your screenshot shows that you've imported the Excel data into your app.
Data that you import into Excel is static/read-only, and you won't be able to add or remove records.
Instead, if you save your Excel spreadsheet to OneDrive and connect to it from there, your original Remove formula will work.
There are more details on how to do this here.
https://learn.microsoft.com/en-us/power-apps/maker/canvas-apps/connections/connection-excel
I will try this
@Sidhant_02 ,I was simply giving you an alternative I know works. If you have a column where no two records in the table have the same value, then that is a unique identifier. I would suspect that in the Contacts Table, that is the name of the person. However I now see @timl 's observation and he is correct - you simply cannot delete records from static data.
Refer my reply
Hi, I had created a new excel on my OneDrive and after connecting it to the Vertical Gallery when I inserted a label the record was not being displayed even after entering proper expression. Could you please let me know what is going wrong @WarrenBelz @timl The Id tab which power apps usually generates when we connect it to an excel is not getting displayed. For the first time it was working fine but there was one issue with Cancel button so I tried adding few records but it threw error so I created a new file but now the records are not shown.
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.
In our never-ending quest to improve we are simplifying the forum hierarchy…
We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…
These are the community rock stars!
Stay up to date on forum activity by subscribing.
WarrenBelz 757 Most Valuable Professional
Michael E. Gernaey 322 Super User 2025 Season 2
MS.Ragavendar 209 Super User 2025 Season 2