Search
 
SCRIPT & CODE EXAMPLE
 

EXCEL

Time and date maths in Excel

=A2-B2	Calculates the difference between the time values in cells A2 and B2.
=TIMEVALUE("8:30 PM") - TIMEVALUE("6:40 AM")	Calculates the difference between the specified times.
=TIME(HOUR(A2), MINUTE(A2), SECOND(A2)) - TIME(HOUR(B2), MINUTE(B2), SECOND(B2))	Calculates the time difference between values in cells A2 and B2 ignoring the date difference, when the cells contain both the date and time values.
Comment

Date and Time maths with Excel

=TEXT(B2-A2, "h:mm:ss")
Comment

PREVIOUS NEXT
Code Example
Excel :: freeze row in excel 
Excel :: google sheets conditional formatting other sheet 
Perl :: perl loops 
Perl :: perl while loop 
Perl :: perl hash ref create 
Perl :: Move files to new directory 
Perl :: what is perl poetry 
Pascal :: pascal press any key to continue 
Pascal :: pascal pause program for seconds 
Pascal :: pascal area 
Powershell :: call function powershell 
Gdscript :: godot get global position 3d 
Clojure :: how to make a range clojure 
Abap :: abap char variable 
Assembly :: pickle dump into specific directory 
Assembly :: wstring to lpcwstr 
Assembly :: sparsefile 
Assembly :: array days of the week 
Javascript :: jquery vslidation remove spaces from input 
Javascript :: week days array in javascrpt 
Javascript :: jquery redirect 
Javascript :: Javascript run code after page load 
Javascript :: react native reset cache 
Javascript :: moment get today, tomorrow, yesterday 
Javascript :: detect browser javascript 
Javascript :: javascript code to edit webpage 
Javascript :: react native rotate 
Javascript :: javascript loop through class elements 
Javascript :: js find object length 
Javascript :: javascript for loop over dictionary 
ADD CONTENT
Topic
Content
Source link
Name
4+1 =