cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Post Prodigy
Post Prodigy

Delete old sharepoint data on submit

Each time the user submits I want it to delete their old data and only store the new radio button selections. This is what I have in my submit button currently Set(varUserEmail, User().Email); Navigate(Success, Fade); ForAll(
TemplateGalleryList1.AllItems,
If(
!IsBlank(Radio4.Selected.Value),
Patch(
'DE Radio',
Defaults('DE Radio'),
{
Title:Namee,
Answer: Radio4.Selected.Value,
Name_:User().FullName,
Date:Today()
}
)
)
); Remove('DE Radio', Filter('DE Radio', 'Created By'.Email = varUserEmail)). The remove function I added removes everything for some reason. I only want it to delete that specific users previous selections.

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Is it removing all items from 'DE Radio' or all items that were created by the current user? If it is the latter then try switching the order of the functions and do the Remove() first and then the Patch().



--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.

View solution in original post

1 REPLY 1
Super User
Super User

Is it removing all items from 'DE Radio' or all items that were created by the current user? If it is the latter then try switching the order of the functions and do the Remove() first and then the Patch().



--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.

View solution in original post

Helpful resources

Announcements
secondImage

Experience what’s next for Power Apps

Join us for an in-depth look at the new Power Apps features and capabilities at the free Microsoft Business Applications Launch Event.

Power Apps Community Call

Power Apps Community Call: February

Did you miss the call? Check out the Power Apps Community Call here.

New Power Super Users

Congratulations!

We are excited to announce the Power Apps Super Users!

New Badges

New Solution Badges!

Check out our new profile badges recognizing authored solutions!

Top Solution Authors
Top Kudoed Authors
Users online (43,404)