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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / CountIf Logical with S...
Power Apps
Answered

CountIf Logical with Sharepoint

(0) ShareShare
ReportReport
Posted on by

Hi all,

 

I'm trying to create a textbox that says how many tasks are due/overdue. The data is stored in sharepoint, with the due date as a date and the completion status as a choice list. Right now it works if I only use the date to determine the number of tasks. However I need to only include assigned tasks so I need to add a second conditional to the formula. Right now I have it set up like so:

 

CountIf('Task Management',Value(Text(Due_Date, "[$-en-US]yyyymmdd")) < Value(Text(Today(), "[$-en-US]yyyymmdd")) && Status = First(Choices('Task Management'.Status)))

 

It stops working once I add the "&&" and everything past it. Does anyone have any advice?

 

Thanks, 

Categories:
I have the same question (0)
  • WarrenBelz Profile Picture
    153,127 Most Valuable Professional on at

    Hi @Anonymous ,

    Your problem is here

    Status = First(Choices('Task Management'.Status)))

    Are you actually after the value chosen in the control?

    CountIf(
     'Task Management',
     DateDiff(
     Due_Date, 
     Today(), 
     Days
     )>0 &&
     Status = YourDropdownName.Selected.Status
    )

     

    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.

  • Verified answer
    Community Power Platform Member Profile Picture
    on at

    The dropdown menu with the choices is a field in the sharepoint, not a dropdown menu in the actual powerapp. But I was able to fiddle with it and get it to work.

     

    Thanks!

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 765 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 272

Last 30 days Overall leaderboard