web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / SharePoint RemoveIf by...
Power Apps
Answered

SharePoint RemoveIf by Date

(0) ShareShare
ReportReport
Posted on by 226 Moderator

This seems like a simple piece of code but nothing is getting removed.

 

I am trying to remove all records from a SharePoint list that fall on a specific date or between a date range.  The following code does not remove any records.

 

 

RemoveIf(
 Usage,
 Created = DateValue("04/03/2023", "en-US")
)

 

 Where have I gone wrong?

Categories:
I have the same question (0)
  • Verified answer
    LaurensM Profile Picture
    12,516 Moderator on at

    Hi @Hack-7,

     

    Created is a DateTime column. When using the equals operator you are looking for records that were created at that exact moment in time (04/03/2023 12:00:00 AM). Please try the following adjustment:

    RemoveIf(
     Usage,
     //Remove all records created on the 3rd of April 2023
     Created >= Date(2023, 04, 03) && Created <= DateTime(2023, 04, 03, 23, 59, 59)
    )

     

    If this solves your question, would you be so kind as to accept it as a solution.
    Thanks!

  • Hack-7 Profile Picture
    226 Moderator on at

    @LaurensM Ha!  I missed that completely.  Cheers

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.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 525 Most Valuable Professional

#2
Haque Profile Picture

Haque 273

#3
Kalathiya Profile Picture

Kalathiya 232 Super User 2026 Season 1

Last 30 days Overall leaderboard