LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to subtract two time?

Solved!
Go to solution
Take the time stamp, convert them to seconds using "Date/time to seconds" VI, substract them...and then use   "seconds to Date/Time" VI......you will get the difference...........
Anil Punnam
CLD
LV 2012, TestStand 4.2..........
0 Kudos
Message 21 of 24
(1,628 Views)
Thank!
0 Kudos
Message 22 of 24
(1,607 Views)

While David's message #20 is a good example of an elapsed time timer, how is that one the answer to your question?

 

Your question was how to subtract two times, which is simple enough, but was complicated by the fact you wanted to use the date/time cluster, and show the result in a time stamp, which as Rolf pointed out in message 14, can't really be done because the concept of different months, etc. falls apart when comparing dates and times.

0 Kudos
Message 23 of 24
(1,605 Views)
Half the problem is figuring out what is asked for, the other half is understanding what is really wanted.....  Smiley Wink
0 Kudos
Message 24 of 24
(1,584 Views)