#1   Report Post  
Posted to microsoft.public.excel.misc
SJ SJ is offline
external usenet poster
 
Posts: 22
Default Time Calculation

I am trying to work out how to calculate the difference between times for
example my sheet is to work out the finishing times of staff, so if their set
time is 17:30 and they finish one night 17:15 and the next 17:45 i need a
formula that allows me to work out the difference but i'm getting stuck with
the negative bit.
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,480
Default Time Calculation

Hi

To display negative times you would need to switch to the 1904 Data system
ToolsCalculation1904 Date

Be aware though, that if you have any dates already entered on the sheet
under the 1900 default system, then those dates will be out by just over 4
years.
--
Regards
Roger Govier

"Sj" wrote in message
...
I am trying to work out how to calculate the difference between times for
example my sheet is to work out the finishing times of staff, so if their
set
time is 17:30 and they finish one night 17:15 and the next 17:45 i need a
formula that allows me to work out the difference but i'm getting stuck
with
the negative bit.


  #3   Report Post  
Posted to microsoft.public.excel.misc
SJ SJ is offline
external usenet poster
 
Posts: 22
Default Time Calculation

Thanks
My cells look like this ( d3 is a set cell)
D3 e3 f3
18:00 18:15 23:45
17:45 18:15 00:30

the formula I have in f3 is this
=IF(E3D3,D3+1-E3,D3-E3)
and in f4
=IF(D4E4,E4+1-D4,E4-D4)

I want to join the two so that when I put a time in e3 it will work out the
difference either way.




"Roger Govier" wrote:

Hi

To display negative times you would need to switch to the 1904 Data system
ToolsCalculation1904 Date

Be aware though, that if you have any dates already entered on the sheet
under the 1900 default system, then those dates will be out by just over 4
years.
--
Regards
Roger Govier

"Sj" wrote in message
...
I am trying to work out how to calculate the difference between times for
example my sheet is to work out the finishing times of staff, so if their
set
time is 17:30 and they finish one night 17:15 and the next 17:45 i need a
formula that allows me to work out the difference but i'm getting stuck
with
the negative bit.



  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,345
Default Time Calculation

Format Conditional Formatting Condition 1 Formula is:

=D3-E3<0

Select the Format button in the dialog box then Font and select Red as the
font colour.

or you may have meant =E3-D<0 as the condition.

--
HTH

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings


Replace @mailinator.com with @tiscali.co.uk


"Sj" wrote in message
...
Yes thanks, now only thing is is if the time is over is there a way it can
be
displayed in red?

"Sandy Mann" wrote:

Would:

=MAX(D3:E3)-MIN(D3:E3)

do what you want?

--
HTH

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings


Replace @mailinator.com with @tiscali.co.uk


"Sj" wrote in message
...
Thanks
My cells look like this ( d3 is a set cell)
D3 e3 f3
18:00 18:15 23:45
17:45 18:15 00:30

the formula I have in f3 is this
=IF(E3D3,D3+1-E3,D3-E3)
and in f4
=IF(D4E4,E4+1-D4,E4-D4)

I want to join the two so that when I put a time in e3 it will work out
the
difference either way.




"Roger Govier" wrote:

Hi

To display negative times you would need to switch to the 1904 Data
system
ToolsCalculation1904 Date

Be aware though, that if you have any dates already entered on the
sheet
under the 1900 default system, then those dates will be out by just
over
4
years.
--
Regards
Roger Govier

"Sj" wrote in message
...
I am trying to work out how to calculate the difference between
times
for
example my sheet is to work out the finishing times of staff, so if
their
set
time is 17:30 and they finish one night 17:15 and the next 17:45 i
need
a
formula that allows me to work out the difference but i'm getting
stuck
with
the negative bit.









  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,480
Default Time Calculation

Hi

=MOD(E3-D3,1)
will give that result for either row.
or
=E3-D3+(D3E3)

The result of 23:45 however, is wrong, if the times are on the same day.
It should be -00:15, but unless you use the a90m as advised previously, you
cannot display negative times.

--
Regards
Roger Govier

"Sj" wrote in message
...
Thanks
My cells look like this ( d3 is a set cell)
D3 e3 f3
18:00 18:15 23:45
17:45 18:15 00:30

the formula I have in f3 is this
=IF(E3D3,D3+1-E3,D3-E3)
and in f4
=IF(D4E4,E4+1-D4,E4-D4)

I want to join the two so that when I put a time in e3 it will work out
the
difference either way.




"Roger Govier" wrote:

Hi

To display negative times you would need to switch to the 1904 Data
system
ToolsCalculation1904 Date

Be aware though, that if you have any dates already entered on the sheet
under the 1900 default system, then those dates will be out by just over
4
years.
--
Regards
Roger Govier

"Sj" wrote in message
...
I am trying to work out how to calculate the difference between times
for
example my sheet is to work out the finishing times of staff, so if
their
set
time is 17:30 and they finish one night 17:15 and the next 17:45 i need
a
formula that allows me to work out the difference but i'm getting stuck
with
the negative bit.



  #8   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,480
Default Time Calculation

but unless you use the a90m as advised previously

Don't know how I managed to type that, I meant to type

but unless you use the 1904 date system as advised previously

--
Regards
Roger Govier

"Roger Govier" <roger@technology4unospamdotcodotuk wrote in message
...
Hi

=MOD(E3-D3,1)
will give that result for either row.
or
=E3-D3+(D3E3)

The result of 23:45 however, is wrong, if the times are on the same day.
It should be -00:15, but unless you use the a90m as advised previously,
you cannot display negative times.

--
Regards
Roger Govier

"Sj" wrote in message
...
Thanks
My cells look like this ( d3 is a set cell)
D3 e3 f3
18:00 18:15 23:45
17:45 18:15 00:30

the formula I have in f3 is this
=IF(E3D3,D3+1-E3,D3-E3)
and in f4
=IF(D4E4,E4+1-D4,E4-D4)

I want to join the two so that when I put a time in e3 it will work out
the
difference either way.




"Roger Govier" wrote:

Hi

To display negative times you would need to switch to the 1904 Data
system
ToolsCalculation1904 Date

Be aware though, that if you have any dates already entered on the sheet
under the 1900 default system, then those dates will be out by just over
4
years.
--
Regards
Roger Govier

"Sj" wrote in message
...
I am trying to work out how to calculate the difference between times
for
example my sheet is to work out the finishing times of staff, so if
their
set
time is 17:30 and they finish one night 17:15 and the next 17:45 i
need a
formula that allows me to work out the difference but i'm getting
stuck
with
the negative bit.


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
Stop time - start time calculation squack21 Excel Worksheet Functions 5 December 10th 07 03:20 PM
Time calculation (Subraction of Idle Time) Ajay Excel Discussion (Misc queries) 6 March 4th 07 11:54 AM
Time Calculation wnfisba Excel Discussion (Misc queries) 5 October 18th 06 01:06 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 11:16 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"