Deleting repeater and its database row through Delete button on repeater

I am trying to create admin page through “Dashboard page” where I am planning to create repeaters connected to Database exactly as in main website. I wanted to add “Edit Button” & “Delete Button” to repeaters so when I click edit button, I get edit form to update and when I click delete button, I delete whole repeater and its row entry in Database collection. Is it possible to do this functionality? Please help. Thank you.

Hi :raised_hand_with_fingers_splayed:

Yes it’s possible, you can edit the item you clicked on by redirecting the admin to another page where he/she can edit the it on a form - I assume that you know how to do so.

Now regarding to the deletion, do you want to delete just the data that’s been displayed on the repeater? Or do you want to delete all the entries on the database?

I want to delete whole repeater and its corresponding entries in database collection. Does this require coding?

Yes it does

Hi, I want to be able to do this (delete data on a particular repeater). Are you able to advise on the appropriate code please? TIA

@crawfordaudrey Hi I changed the dataset settings to read & write and added a delete button to repeater, connected delete button to “Delete” option through database icon. I did it without coding. It will delete only repeater which you want to delete.

@crawfordaudrey If you’re using a dataset, just connect the button to the ‘Delete’ action, if not then just send the ID if the item to the backend to remove the item to delete it, and use the array.slice() method to remove the item from the repeater’s data array.

Hello Parthasarathy,

Even I did the same, but i m unable delete only repeater which I want to delete.
Is there any code that we have to write to select the particular repeater and connect the delete button to “Delete” option through Database icon.