# Calculate Time Duration

**URL:** <https://community.thunkable.com/t/calculate-time-duration/1361156>\
**Category:** Questions about Thunkable X\
**Created:** [June 24, 2021, 5:35am UTC](https://community.thunkable.com/t/calculate-time-duration/1361156 "2021-06-24T05:35:01Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![jane](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/jane/32/27575_2.png) [@jane](https://community.thunkable.com/u/jane)\
**Post date:** [June 24, 2021, 9:46am UTC](https://community.thunkable.com/t/calculate-time-duration/1361156/6 "2021-06-24T09:46:44Z")

</div>

Hi there,

You can view a project [here](https://x.thunkable.com/projectPage/60d44d1394ea3200113c32eb/) that will calculate the difference between a given start time and the current time.

This project calculates the total minutes between the current time and the given start time.  
This is done by calculating `(difference in hours * 60) + (difference in minutes)`  
(Eg. if the event starts at 10.30 and it is currently 9.45, the total minutes = `(1 * 60) + (-15) = 45`)

 ![Screen Shot 2021-06-24 at 10.44.58 AM](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/6/9/69b28c054e821df01a783f0cf8fd24a31fb64d97.png)

If this is total number of minutes is 0, it says that the event is starting right now.  
If this is greater than 0, it says that the event starts in X hours and Y minutes.  
If it is less than 0, it says that you are late! The event started X hours and Y minutes ago.  
(X = total minutes divided by 60, Y = remainder of total minutes divided by 60).

 ![Screen Shot 2021-06-24 at 10.45.28 AM](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/e/c/ec3d9bfd9de9ca00541793cefbc48b3d7a9b43b1.png)

---

_[View the full topic](https://community.thunkable.com/t/calculate-time-duration/1361156)._
