# Subtract Datetimes

**URL:** <https://forum.inductiveautomation.com/t/subtract-datetimes/18383>\
**Category:** Ignition\
**Created:** [June 11, 2018, 1:41am UTC](https://forum.inductiveautomation.com/t/subtract-datetimes/18383 "2018-06-11T01:41:51Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ruica.cristina](https://avatars.discourse-cdn.com/v4/letter/r/898d66/32.png) [@ruica.cristina](https://forum.inductiveautomation.com/u/ruica.cristina)\
**Post date:** [June 11, 2018, 1:41am UTC](https://forum.inductiveautomation.com/t/subtract-datetimes/18383/1 "2018-06-11T01:41:51Z")

</div>

I have a project with some temperature values which I want to "test’. The test is about “real-time” matter… So… I want in my project a field in which i will put the difference of time in miliseconds between the "now’ time(the time when the value is showed), and the “LastChange” from the value tag… In order to show that the values are realy showed in real-time… Some help, please?

---

<div class="post-metadata">

**Author:** ![witman](https://avatars.discourse-cdn.com/v4/letter/w/d2c977/32.png) [@witman](https://forum.inductiveautomation.com/u/witman)\
**Post date:** [June 11, 2018, 2:18am UTC](https://forum.inductiveautomation.com/t/subtract-datetimes/18383/2 "2018-06-11T02:18:07Z")

</div>

If I understand what you are trying to accomplish correctly, you would probably want the value to use an expression binding using functions from [https://docs.inductiveautomation.com/display/DOC79/Date+and+Time](https://docs.inductiveautomation.com/display/DOC79/Date+and+Time). Something like:

```auto
secondsBetween(now(), {TagPath.LastChange})

```
