Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 385
Default Summing up different time formats

I have a file in excel where there are five columns that have time formated
as basic numeric. Example: 30 minutes displays as 30, 10 hours displays as
10. How do I show these 5 columns as hours ?
Second question: I have an additional column where the time is displayed as
minutes (on the same worksheet as the five columns). I placed a formula where
it changes it to hours/minutes (= cell/1440) and then format the cell ([h]:mm.

Now I am trying to sum the 6 columns in the worksheet to get the total hours
and is not working. Any suggestions ?


  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,358
Default Summing up different time formats

Suppose columns A & B have hours listed as whole numbers, columns C & E have
minutes listed as whole numbers, and columns D & F have seconds displayed as
whole numbers.
=TIME(A2+B2,C2+E2,D2+F2)
Format this total cell as [hh]:mm:ss
--
** John C **

"Jennifer" wrote:

I have a file in excel where there are five columns that have time formated
as basic numeric. Example: 30 minutes displays as 30, 10 hours displays as
10. How do I show these 5 columns as hours ?
Second question: I have an additional column where the time is displayed as
minutes (on the same worksheet as the five columns). I placed a formula where
it changes it to hours/minutes (= cell/1440) and then format the cell ([h]:mm.

Now I am trying to sum the 6 columns in the worksheet to get the total hours
and is not working. Any suggestions ?


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,501
Default Summing up different time formats

Jennifer

To change a decimal number to time you need to know whether the column
relates to hrs or minutes so assuming A1 refers to minutes, use this and
format as [h]:mm

=TIME(0,A1,0)

Likewise if A1 contained hours use

=TIME(A1,0,0)

The simply sum them in the way you have already indicated.

Mike




"Jennifer" wrote:

I have a file in excel where there are five columns that have time formated
as basic numeric. Example: 30 minutes displays as 30, 10 hours displays as
10. How do I show these 5 columns as hours ?
Second question: I have an additional column where the time is displayed as
minutes (on the same worksheet as the five columns). I placed a formula where
it changes it to hours/minutes (= cell/1440) and then format the cell ([h]:mm.

Now I am trying to sum the 6 columns in the worksheet to get the total hours
and is not working. Any suggestions ?


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 385
Default Summing up different time formats

John,
I am receving an error when I try the formula below.The error is: You have
entered to few arguments for this funcation. Here is what I typed:
=time(F5+G5+H5+I5+J5+M5)
F5 thru J5 is formatted as general format
M5 is formatted as h:mm

Should I format the columns differently ?
The columns F5 thru J5 were manually entered
F5 30
G5 3
H5 10
I5 27.5
J5 is 40

All are represent how many hours except F5 this means 30 minutes.

M5 varies but is formatted as h:mm, but as an example we can use 2:17 (which
would be 2 hrs and 17 minutes. Was 137 minutes.

"John C" wrote:

Suppose columns A & B have hours listed as whole numbers, columns C & E have
minutes listed as whole numbers, and columns D & F have seconds displayed as
whole numbers.
=TIME(A2+B2,C2+E2,D2+F2)
Format this total cell as [hh]:mm:ss
--
** John C **

"Jennifer" wrote:

I have a file in excel where there are five columns that have time formated
as basic numeric. Example: 30 minutes displays as 30, 10 hours displays as
10. How do I show these 5 columns as hours ?
Second question: I have an additional column where the time is displayed as
minutes (on the same worksheet as the five columns). I placed a formula where
it changes it to hours/minutes (= cell/1440) and then format the cell ([h]:mm.

Now I am trying to sum the 6 columns in the worksheet to get the total hours
and is not working. Any suggestions ?


  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,358
Default Summing up different time formats

The time function has 3 separate arguments, which must be separated by commas.
=TIME(hours,minutes,seconds)
So, if all of the cells F5, G5, H5, I5, and J5 are hours, and you want to
display the result in M5, then
M5: =TIME(F5+G5+H5+I5+J5,,) or, written another way
M5: =TIME(SUM(F5:J5),,)
If, however, as you stated in your original post, some of the columns are
minutes, and some are hours, say for example, G5 and H5 are hours in whole
numbers, and F5, I5, and J5 are minutes in whole numbers, then you could have
your formula in M5 like so:
M5: =TIME(G5+H5,F5+I5+J5,)
I would format M5 as either [hh]:mm or even [hh]:mm:ss just in case your
time goes over 24 hours.
--
** John C **

"Jennifer" wrote:

John,
I am receving an error when I try the formula below.The error is: You have
entered to few arguments for this funcation. Here is what I typed:
=time(F5+G5+H5+I5+J5+M5)
F5 thru J5 is formatted as general format
M5 is formatted as h:mm

Should I format the columns differently ?
The columns F5 thru J5 were manually entered
F5 30
G5 3
H5 10
I5 27.5
J5 is 40

All are represent how many hours except F5 this means 30 minutes.

M5 varies but is formatted as h:mm, but as an example we can use 2:17 (which
would be 2 hrs and 17 minutes. Was 137 minutes.

"John C" wrote:

Suppose columns A & B have hours listed as whole numbers, columns C & E have
minutes listed as whole numbers, and columns D & F have seconds displayed as
whole numbers.
=TIME(A2+B2,C2+E2,D2+F2)
Format this total cell as [hh]:mm:ss
--
** John C **

"Jennifer" wrote:

I have a file in excel where there are five columns that have time formated
as basic numeric. Example: 30 minutes displays as 30, 10 hours displays as
10. How do I show these 5 columns as hours ?
Second question: I have an additional column where the time is displayed as
minutes (on the same worksheet as the five columns). I placed a formula where
it changes it to hours/minutes (= cell/1440) and then format the cell ([h]:mm.

Now I am trying to sum the 6 columns in the worksheet to get the total hours
and is not working. Any suggestions ?




  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 385
Default Summing up different time formats

Okay works for the columns that have 30 mins, 3 hrs, 20 hrs, but for the
columns that have 40 hrs (listed as general format) and the column that has
27.5 (listed as general format) it does not sum properly. Here are examples
of what I have:

1,650 (formatted general - is 27 hours and 30 minutes) column I
24 (formatted general - 24 minutes) column k

I used the formula in cell O2 = time(,I2+K2,)
my results were 03:54 instead of 27:54.
I did format the cell O2 as [hh]:mm

"John C" wrote:

The time function has 3 separate arguments, which must be separated by commas.
=TIME(hours,minutes,seconds)
So, if all of the cells F5, G5, H5, I5, and J5 are hours, and you want to
display the result in M5, then
M5: =TIME(F5+G5+H5+I5+J5,,) or, written another way
M5: =TIME(SUM(F5:J5),,)
If, however, as you stated in your original post, some of the columns are
minutes, and some are hours, say for example, G5 and H5 are hours in whole
numbers, and F5, I5, and J5 are minutes in whole numbers, then you could have
your formula in M5 like so:
M5: =TIME(G5+H5,F5+I5+J5,)
I would format M5 as either [hh]:mm or even [hh]:mm:ss just in case your
time goes over 24 hours.
--
** John C **

"Jennifer" wrote:

John,
I am receving an error when I try the formula below.The error is: You have
entered to few arguments for this funcation. Here is what I typed:
=time(F5+G5+H5+I5+J5+M5)
F5 thru J5 is formatted as general format
M5 is formatted as h:mm

Should I format the columns differently ?
The columns F5 thru J5 were manually entered
F5 30
G5 3
H5 10
I5 27.5
J5 is 40

All are represent how many hours except F5 this means 30 minutes.

M5 varies but is formatted as h:mm, but as an example we can use 2:17 (which
would be 2 hrs and 17 minutes. Was 137 minutes.

"John C" wrote:

Suppose columns A & B have hours listed as whole numbers, columns C & E have
minutes listed as whole numbers, and columns D & F have seconds displayed as
whole numbers.
=TIME(A2+B2,C2+E2,D2+F2)
Format this total cell as [hh]:mm:ss
--
** John C **

"Jennifer" wrote:

I have a file in excel where there are five columns that have time formated
as basic numeric. Example: 30 minutes displays as 30, 10 hours displays as
10. How do I show these 5 columns as hours ?
Second question: I have an additional column where the time is displayed as
minutes (on the same worksheet as the five columns). I placed a formula where
it changes it to hours/minutes (= cell/1440) and then format the cell ([h]:mm.

Now I am trying to sum the 6 columns in the worksheet to get the total hours
and is not working. Any suggestions ?


  #7   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,240
Default Summing up different time formats

Jennifer wrote:
Okay works for the columns that have 30 mins, 3 hrs, 20 hrs, but for the
columns that have 40 hrs (listed as general format) and the column that has
27.5 (listed as general format) it does not sum properly. Here are examples
of what I have:

1,650 (formatted general - is 27 hours and 30 minutes) column I
24 (formatted general - 24 minutes) column k

I used the formula in cell O2 = time(,I2+K2,)
my results were 03:54 instead of 27:54.
I did format the cell O2 as [hh]:mm


The TIME() function does not understand anything over 24 hours. From the help file:

The decimal number returned by TIME is a value ranging from 0 (zero) to
0.99999999, representing the times from 0:00:00 (12:00:00 AM) to 23:59:59
(11:59:59 P.M.).

If you have hours in A2 and B2, minutes in C2 and D2, then your result in E2
should be this:

=(A2+B2)/24+(C2+D2)/1440
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Need help summing time ascottbag-hcm Excel Worksheet Functions 6 September 17th 08 11:17 PM
summing time kevcar40 Excel Discussion (Misc queries) 2 February 8th 08 09:05 AM
summing of time Andrew@rushington[_2_] Excel Worksheet Functions 3 November 30th 07 07:59 AM
Converting time formats into actual time(minutes) LeighM Excel Discussion (Misc queries) 2 October 30th 06 05:15 AM
Summing Time JDT Excel Discussion (Misc queries) 8 February 8th 05 10:53 PM


All times are GMT +1. The time now is 11:03 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"