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 / Calculate Ageing - Dat...
Power Apps
Answered

Calculate Ageing - Date Today less Created Date

(0) ShareShare
ReportReport
Posted on by 166

Hi,

 

I am creating a value card wherein I want to return the number of days (Date Today less Date Created).

 

The list is in number format and in whole number only. 

 

I want to return the number of days (age) as the default value for this.

 

Can you help me build the default value for this?

Categories:
I have the same question (0)
  • Verified answer
    WarrenBelz Profile Picture
    156,382 Most Valuable Professional on at

    HI @ComicSansrival ,

    You have not stated your Data Source or where you want this calculated, but assuming you are using SharePoint and you want the value for a record in a Form or a Gallery, this should do it

    DateDiff(
     ThisItem.Created,
     Today(),
     TimeUnit.Days
    )

     

    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.

    MVP (Business Applications)   Visit my blog Practical Power Apps

  • ComicSansrival Profile Picture
    166 on at

    Hi,

     

    I would like to add question:

     

    I want to add an if condition since I want to stop the counting the agein if the card is set to "closed"

     

    ComicSansrival_0-1696218670601.png

     

    I want to compute the age based on today's date less created date if status value card is set to open or if this is set to closed then show the number of days between query resolution date and created date.

  • WarrenBelz Profile Picture
    156,382 Most Valuable Professional on at

    @ComicSansrival ,

    I am assuming the field names are as per your labels here

    DateDiff(
     ThisItem.Created,
     If(
     ThisItem.Status = "Closed",
     ThisItem.'Query Resolution Date',
     Today()
     ),
     TimeUnit.Days
    )

     

    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.

    MVP (Business Applications)   Visit my blog Practical Power Apps

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 416 Most Valuable Professional

#2
11manish Profile Picture

11manish 205 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 128 Super User 2026 Season 2

Last 30 days Overall leaderboard