cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
radhi-bh
Helper I
Helper I

Delete collection item record using SPList data and in-app text input

Hi all,

 

Using sample Estimator Pro app as a base. 

 

I'm able to create a collection entry using sharepoint product list data and a text input used for Quantity. But I'm unable to get the remove button to work. 

 

Buttons available

 

ProductAdd

Original: 

 

 

If(IsBlank(LookUp(SelectedProducts, ID=ThisItem.ID,ID)),Collect(SelectedProducts,ThisItem);

 

 

Changed it to, and it worked in adding Quantity in the collection

 

 

If(IsBlank(LookUp(SelectedProducts, ID=ThisItem.ID,ID)),Collect(SelectedProducts, AddColumns(Table(ThisItem), "Quantity", ProductGallery.Selected.QuantityNumberBox.Text)))

 

 

 

ProductAdded

 

 

Remove(SelectedProducts, ThisItem)

 

 

 

ProductAdded_1

 

 

Remove(SelectedProducts,ThisItem)

 

 

 

radhi-bh_0-1599975823140.png

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
WarrenBelz
Super User III
Super User III

Hi @radhi-bh ,

Try

RemoveIf(
   SelectedProducts, 
   ID=ThisItem.ID
)

I am assuming the remove icon is inside the gallery.

 

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.

View solution in original post

2 REPLIES 2
WarrenBelz
Super User III
Super User III

Hi @radhi-bh ,

Try

RemoveIf(
   SelectedProducts, 
   ID=ThisItem.ID
)

I am assuming the remove icon is inside the gallery.

 

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.

View solution in original post

Thank you so much @WarrenBelz , that got it to work - finally. And yes the remove button is hidden.

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

secondImage

Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Power Apps June 2021

June Power Apps Community Call

Don't miss the call this month on June 16th - 8a PDT

Top Solution Authors
Top Kudoed Authors
Users online (38,309)