Quantcast
Channel: How do I get the difference between two Dates in JavaScript? - Stack Overflow
Viewing all articles
Browse latest Browse all 20

How do I get the difference between two Dates in JavaScript?

$
0
0

I'm creating an application which lets you define events with a time frame. I want to automatically fill in the end date when the user selects or changes the start date. I can't quite figure out, however, how to get the difference between the two times, and then how to create a new end Date using that difference.


Viewing all articles
Browse latest Browse all 20

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>