Calculating Difference Between Two Times in General Format

M

MGranger

I am using a google document survey to have users enter times in a military
format. The result is pasted into excel as a "General" format number, like
2253 to represent 10:53PM. They do not enter the semicolon between hours and
minutes.

I need to see the number of minutes between two times, such as 2257 - 2253
or 4 minutes.

How can I convert general numbers, some of which are 04 to represent 00:04
AM, to serial times or time format?

Thanks very much in advance.
 
J

Jacob Skaria

Suppose
A1 = 2257 (formated as text)
B1 = 2253 (formated as text)

Try the below formula in C1 (formatted as hh:mm)

=TIME(INT(LEFT(A1,2)-LEFT(B1,2)),INT(RIGHT(A1,2)-RIGHT(B1,2)),0)

If this post helps click Yes
 
R

Ron Rosenfeld

I am using a google document survey to have users enter times in a military
format. The result is pasted into excel as a "General" format number, like
2253 to represent 10:53PM. They do not enter the semicolon between hours and
minutes.

I need to see the number of minutes between two times, such as 2257 - 2253
or 4 minutes.

How can I convert general numbers, some of which are 04 to represent 00:04
AM, to serial times or time format?

Thanks very much in advance.

And a numeric solution:

=(INT(A1/100)+MOD(A1,100)/60-
(INT(B1/100)+MOD(B1,100)/60))*60

And another method, if you have either Excel 2007+ or have installed the
Analysis Tool Pak:

=(DOLLARDE(A1/100,60)-DOLLARDE(B1/100,60))*60

--ron
 
R

Rick Rothstein

I am using a google document survey to have users enter times in a
And a numeric solution:

=(INT(A1/100)+MOD(A1,100)/60-
(INT(B1/100)+MOD(B1,100)/60))*60

And another method, if you have either Excel 2007+ or have installed the
Analysis Tool Pak:

=(DOLLARDE(A1/100,60)-DOLLARDE(B1/100,60))*60

Another method (making use of the formula David posted)...

=1440*(TEXT(A1,"00\:00")-TEXT(B1,"00\:00"))
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top