Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 111
Default Time calculation probolem request

To all,

This is probably a very obvious question, but I cant get my head
around it. I have two cells containing the values 22:01:50 and
22:01:42. When I subtract 22:01:42 from 22:01:50, I get 00:00:08.
Which is fine. However I want the 00:00:08 to just read 8. I.e. just a
normal number. Ive tried formating the cells, but this doesn't work.

Is this possible?

Thanks in advance for your help,

Regards

Joseph Crabtree


  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,059
Default Time calculation probolem request

On Nov 27, 11:28 pm, joecrabtree wrote:
To all,

This is probably a very obvious question, but I cant get my head
around it. I have two cells containing the values 22:01:50 and
22:01:42. When I subtract 22:01:42 from 22:01:50, I get 00:00:08.
Which is fine. However I want the 00:00:08 to just read 8.


If 22:01:50 is in A1 and 22:01:42 is in A2, compute:

=round((A1-A2)*24*3600,0)

and format Number with zero decimal places. You can replace 24*3600
with 86400, the number of seconds in a day. The "problem" is: time
is stored as a fraction of a day.
  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 287
Default Time calculation probolem request

You could also try formatting the result cell as [s]

Note: this only changes the display not the underlying value

"joeu2004" wrote:

On Nov 27, 11:28 pm, joecrabtree wrote:
To all,

This is probably a very obvious question, but I cant get my head
around it. I have two cells containing the values 22:01:50 and
22:01:42. When I subtract 22:01:42 from 22:01:50, I get 00:00:08.
Which is fine. However I want the 00:00:08 to just read 8.


If 22:01:50 is in A1 and 22:01:42 is in A2, compute:

=round((A1-A2)*24*3600,0)

and format Number with zero decimal places. You can replace 24*3600
with 86400, the number of seconds in a day. The "problem" is: time
is stored as a fraction of a day.

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
request for time interval worksheet function Zb Kornecki Excel Discussion (Misc queries) 1 March 12th 07 05:36 AM
Time calculation (Subraction of Idle Time) Ajay Excel Discussion (Misc queries) 6 March 4th 07 11:54 AM
Working days and hours calculation - request assistance please! sbickley Excel Worksheet Functions 0 August 16th 06 06:37 PM
Ignoring Time in a Date Time Calculation nmp Excel Worksheet Functions 3 November 23rd 05 08:32 PM
time calculation with military time Ron Thetford Excel Worksheet Functions 8 July 29th 05 07:24 PM


All times are GMT +1. The time now is 08:28 AM.

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

About Us

"It's about Microsoft Excel"