A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » Worksheet Functions
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Difference between date and time



 
 
Thread Tools Display Modes
  #1  
Old June 12th, 2009, 03:55 PM posted to microsoft.public.excel.worksheet.functions
joshua
external usenet poster
 
Posts: 46
Default Difference between date and time

I am trying to get the difference between date and time into the hh:mm format.
Example:

Start Date End Date Time taken to complete
7-1-09 8:00 AM 7-2-09 8:30 AM 24:30

How can i get it to calculate the difference between the date and the time
  #2  
Old June 12th, 2009, 04:02 PM posted to microsoft.public.excel.worksheet.functions
Mike H
external usenet poster
 
Posts: 8,419
Default Difference between date and time

Joshua,

Simply subtract the earlier from the later tiem

=B1-A1

and then format that cell with

[h]:mm

Mike



"Joshua" wrote:

I am trying to get the difference between date and time into the hh:mm format.
Example:

Start Date End Date Time taken to complete
7-1-09 8:00 AM 7-2-09 8:30 AM 24:30

How can i get it to calculate the difference between the date and the time

  #3  
Old June 12th, 2009, 04:03 PM posted to microsoft.public.excel.worksheet.functions
Bernard Liengme[_2_]
external usenet poster
 
Posts: 1,027
Default Difference between date and time

=B1-A1
Format the cell with custom format [h]:mm to see 2:30 or 24:30, or with
[hh]:mm to see 02:30 or 24:30
The [ ] are needed to get Excel to display more that 24 hours
best wishes
--
Bernard V Liengme
Microsoft Excel MVP
http://people.stfx.ca/bliengme
remove caps from email


"Joshua" wrote in message
...
I am trying to get the difference between date and time into the hh:mm
format.
Example:

Start Date End Date Time taken to complete
7-1-09 8:00 AM 7-2-09 8:30 AM 24:30

How can i get it to calculate the difference between the date and the time



  #4  
Old June 12th, 2009, 04:05 PM posted to microsoft.public.excel.worksheet.functions
Jacob Skaria
external usenet poster
 
Posts: 5,952
Default Difference between date and time

Sum and difference same as numerics. except that it should be formatted to

[h]:mm:ss

If this post helps click Yes
---------------
Jacob Skaria


"Joshua" wrote:

I am trying to get the difference between date and time into the hh:mm format.
Example:

Start Date End Date Time taken to complete
7-1-09 8:00 AM 7-2-09 8:30 AM 24:30

How can i get it to calculate the difference between the date and the time

  #5  
Old June 12th, 2009, 04:23 PM posted to microsoft.public.excel.worksheet.functions
joshua
external usenet poster
 
Posts: 46
Default Difference between date and time

Thank you that helped alot

I also want to know if anything has gone over a 24hr time limit
before I had it calculate =IF(C324,"NO","YES")
so if C3 was 25:00 it would give me a NO or 23:00 a yes
right now it gives me all YES even if it is over 24
Do I have to change the format of =IF cell or input a new formula

Thanks for your time

"Bernard Liengme" wrote:

=B1-A1
Format the cell with custom format [h]:mm to see 2:30 or 24:30, or with
[hh]:mm to see 02:30 or 24:30
The [ ] are needed to get Excel to display more that 24 hours
best wishes
--
Bernard V Liengme
Microsoft Excel MVP
http://people.stfx.ca/bliengme
remove caps from email


"Joshua" wrote in message
...
I am trying to get the difference between date and time into the hh:mm
format.
Example:

Start Date End Date Time taken to complete
7-1-09 8:00 AM 7-2-09 8:30 AM 24:30

How can i get it to calculate the difference between the date and the time




  #6  
Old June 12th, 2009, 04:32 PM posted to microsoft.public.excel.worksheet.functions
Jacob Skaria
external usenet poster
 
Posts: 5,952
Default Difference between date and time

Try. 24 should not be a numeric but should be in time format//

=IF(E24TIME(24,0,0),"NO","Yes")

If this post helps click Yes
---------------
Jacob Skaria


"Joshua" wrote:

Thank you that helped alot

I also want to know if anything has gone over a 24hr time limit
before I had it calculate =IF(C324,"NO","YES")
so if C3 was 25:00 it would give me a NO or 23:00 a yes
right now it gives me all YES even if it is over 24
Do I have to change the format of =IF cell or input a new formula

Thanks for your time

"Bernard Liengme" wrote:

=B1-A1
Format the cell with custom format [h]:mm to see 2:30 or 24:30, or with
[hh]:mm to see 02:30 or 24:30
The [ ] are needed to get Excel to display more that 24 hours
best wishes
--
Bernard V Liengme
Microsoft Excel MVP
http://people.stfx.ca/bliengme
remove caps from email


"Joshua" wrote in message
...
I am trying to get the difference between date and time into the hh:mm
format.
Example:

Start Date End Date Time taken to complete
7-1-09 8:00 AM 7-2-09 8:30 AM 24:30

How can i get it to calculate the difference between the date and the time




  #7  
Old June 12th, 2009, 05:10 PM posted to microsoft.public.excel.worksheet.functions
T. Valko
external usenet poster
 
Posts: 15,759
Default Difference between date and time

=IF(E24TIME(24,0,0),"NO","Yes")

Look in Excel help on the TIME function and see what it says about the HOUR
argument.

Try it like this:

=IF(E241,"NO","Yes")

--
Biff
Microsoft Excel MVP


"Jacob Skaria" wrote in message
...
Try. 24 should not be a numeric but should be in time format//

=IF(E24TIME(24,0,0),"NO","Yes")

If this post helps click Yes
---------------
Jacob Skaria


"Joshua" wrote:

Thank you that helped alot

I also want to know if anything has gone over a 24hr time limit
before I had it calculate =IF(C324,"NO","YES")
so if C3 was 25:00 it would give me a NO or 23:00 a yes
right now it gives me all YES even if it is over 24
Do I have to change the format of =IF cell or input a new formula

Thanks for your time

"Bernard Liengme" wrote:

=B1-A1
Format the cell with custom format [h]:mm to see 2:30 or 24:30, or
with
[hh]:mm to see 02:30 or 24:30
The [ ] are needed to get Excel to display more that 24 hours
best wishes
--
Bernard V Liengme
Microsoft Excel MVP
http://people.stfx.ca/bliengme
remove caps from email


"Joshua" wrote in message
...
I am trying to get the difference between date and time into the
hh:mm
format.
Example:

Start Date End Date Time taken to
complete
7-1-09 8:00 AM 7-2-09 8:30 AM 24:30

How can i get it to calculate the difference between the date and the
time





  #8  
Old June 12th, 2009, 05:22 PM posted to microsoft.public.excel.worksheet.functions
Rich/rerat
external usenet poster
 
Posts: 423
Default Difference between date and time

Joshua,
With Row#1 as your Field Headers:
"A" Column: Start Time
"B" Column: Finish Time
"C" Column: Total Hrs formatted as [H]:mm:ss
"D" Column: Yes/No

You can use the following formula in your "Yes/No" column, with Row#1 as
your Field Headers:
=IF($A2="","",IF((B2-A2)*2424,"NO","YES"))
This will give you a "YES" response for 24 hrs, if you want a "NO" response
for 24 hrs use this:
=IF($A2="","",IF((B2-A2)*24=24,"NO","YES"))
Drag formula down the column.
You can leave the Cell format for that Column as "General".

--
Add MS to your News Reader: news://msnews.microsoft.com
Rich/rerat
(RRR News) message rule
Previous Text Snipped to Save Bandwidth When Appropriate


"Joshua" wrote in message
...
Thank you that helped alot

I also want to know if anything has gone over a 24hr time limit
before I had it calculate =IF(C324,"NO","YES")
so if C3 was 25:00 it would give me a NO or 23:00 a yes
right now it gives me all YES even if it is over 24
Do I have to change the format of =IF cell or input a new formula

Thanks for your time

"Bernard Liengme" wrote:

=B1-A1
Format the cell with custom format [h]:mm to see 2:30 or 24:30, or with
[hh]:mm to see 02:30 or 24:30
The [ ] are needed to get Excel to display more that 24 hours
best wishes
--
Bernard V Liengme
Microsoft Excel MVP
http://people.stfx.ca/bliengme
remove caps from email


"Joshua" wrote in message
...
I am trying to get the difference between date and time into the hh:mm
format.
Example:

Start Date End Date Time taken to
complete
7-1-09 8:00 AM 7-2-09 8:30 AM 24:30

How can i get it to calculate the difference between the date and the
time






 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 10:35 PM.


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