Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 2
Default times and Calculations

Hello!
I want to calculate # of hours worked in this example:

C1 10:00 am
D1 3:00 pm
I want to display the duration of 5 hours.

TKU
  #2   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 3,268
Default times and Calculations

=D1-C1


--


Regards,


Peo Sjoblom




"professor_ed" wrote in message
...
Hello!
I want to calculate # of hours worked in this example:

C1 10:00 am
D1 3:00 pm
I want to display the duration of 5 hours.

TKU



  #3   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 2
Default times and Calculations

Thank you for the speedy response! The result of the calculation was 5:00PM.
I need the result to be 5. I tried changing the values of thr receiving
cells, but could not get the result to show 5. Cells C1 & D1 are defines as
hh mm ampm

"Peo Sjoblom" wrote:

=D1-C1


--


Regards,


Peo Sjoblom




"professor_ed" wrote in message
...
Hello!
I want to calculate # of hours worked in this example:

C1 10:00 am
D1 3:00 pm
I want to display the duration of 5 hours.

TKU




  #4   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 3,268
Default times and Calculations

if you want it to be 5 decimal format you need to multiply the result with
24 and format the cell as general or number (not time), if you want 05:00 as
a result you need to format the result as hh:mm

=(D1-C1)*24


formatted as general will return 5
--

Regards,

Peo Sjoblom




"professor_ed" wrote in message
...
Thank you for the speedy response! The result of the calculation was
5:00PM.
I need the result to be 5. I tried changing the values of thr receiving
cells, but could not get the result to show 5. Cells C1 & D1 are defines
as
hh mm ampm

"Peo Sjoblom" wrote:

=D1-C1


--


Regards,


Peo Sjoblom




"professor_ed" wrote in message
...
Hello!
I want to calculate # of hours worked in this example:

C1 10:00 am
D1 3:00 pm
I want to display the duration of 5 hours.

TKU






  #5   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 8,651
Default times and Calculations

But if you say it says 5:00PM, then I would expect it to convert to 17, not
5.
If your original inputs were 10:00 am and 3:00 pm, then if you have the
result cell formatted as h:mm AM/PM, the formula =D1-C1 ought to display as
5:00 AM (not PM), but to get it to show 5:00, you can change the format to
[h]:mm. To convert to decimal hours, use Peo's formula.
--
David Biddulph

"Peo Sjoblom" wrote in message
...
if you want it to be 5 decimal format you need to multiply the result with
24 and format the cell as general or number (not time), if you want 05:00
as a result you need to format the result as hh:mm

=(D1-C1)*24
formatted as general will return 5
--
"professor_ed" wrote in message
...
Thank you for the speedy response! The result of the calculation was
5:00PM.
I need the result to be 5. I tried changing the values of thr receiving
cells, but could not get the result to show 5. Cells C1 & D1 are defines
as
hh mm ampm


"Peo Sjoblom" wrote:

=D1-C1


"professor_ed" wrote in message
...
Hello!
I want to calculate # of hours worked in this example:

C1 10:00 am
D1 3:00 pm
I want to display the duration of 5 hours.





  #6   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 3,268
Default times and Calculations

Thanks for the heads up


--


Regards,


Peo Sjoblom



"David Biddulph" <groups [at] biddulph.org.uk wrote in message
...
But if you say it says 5:00PM, then I would expect it to convert to 17,
not 5.
If your original inputs were 10:00 am and 3:00 pm, then if you have the
result cell formatted as h:mm AM/PM, the formula =D1-C1 ought to display
as 5:00 AM (not PM), but to get it to show 5:00, you can change the format
to [h]:mm. To convert to decimal hours, use Peo's formula.
--
David Biddulph

"Peo Sjoblom" wrote in message
...
if you want it to be 5 decimal format you need to multiply the result
with 24 and format the cell as general or number (not time), if you want
05:00 as a result you need to format the result as hh:mm

=(D1-C1)*24
formatted as general will return 5
--
"professor_ed" wrote in message
...
Thank you for the speedy response! The result of the calculation was
5:00PM.
I need the result to be 5. I tried changing the values of thr receiving
cells, but could not get the result to show 5. Cells C1 & D1 are defines
as
hh mm ampm


"Peo Sjoblom" wrote:

=D1-C1


"professor_ed" wrote in message
...
Hello!
I want to calculate # of hours worked in this example:

C1 10:00 am
D1 3:00 pm
I want to display the duration of 5 hours.





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
Averaging times (similar to lap times) cqmman Excel Discussion (Misc queries) 1 June 22nd 07 11:15 PM
Difference in dates calculations except between certain times. Steve Hud Excel Discussion (Misc queries) 1 January 13th 06 01:10 PM
Calculation of hourly rate times hours times 1.5 Newbusinessbod Excel Worksheet Functions 1 December 6th 05 04:44 PM
How are relay leg times or driving times entered and totaled? commissioner Excel Worksheet Functions 1 July 26th 05 09:27 PM
Charting and analyzing Times' times data for trends Johnny Excel Discussion (Misc queries) 1 May 5th 05 01:36 AM


All times are GMT +1. The time now is 12:23 PM.

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"