![]() |
Subtracting Dates
Hi,
how do I subtract the dates? I have a date in one cell and a date in another. i wish to know the difference with respect to the number of days between the two dates. wt formula shud b used in the next cell? Simply applying the formula =A1-A2 gives me an absurd date in A3? i need the no of days. thx for help. |
Subtracting Dates
Format result as general not date
-- Regards, Peo Sjoblom "Malik" wrote in message ... Hi, how do I subtract the dates? I have a date in one cell and a date in another. i wish to know the difference with respect to the number of days between the two dates. wt formula shud b used in the next cell? Simply applying the formula =A1-A2 gives me an absurd date in A3? i need the no of days. thx for help. |
Subtracting Dates
You can try this:
A1 : 01 Oct 07 A2 : 31 Dec 08 A3 : =DATEDIF(A1,A2,"YD"), 91 DAYS or A3 : =DATEDIF(A1,A2,"D"), 457 DAYS If you want more details, check out this thread. David Biddulph & Claude Jerry gave a long explanation on DateDIF function. http://www.microsoft.com/office/comm...2fsettings.xml "Malik" wrote: Hi, how do I subtract the dates? I have a date in one cell and a date in another. i wish to know the difference with respect to the number of days between the two dates. wt formula shud b used in the next cell? Simply applying the formula =A1-A2 gives me an absurd date in A3? i need the no of days. thx for help. |
Subtracting Dates
Yes, but you don't need DATEDIF if you just want a number of days. =A2-A1
is fine, but the answer needs to be formatted as Number or General, not as a date. -- David Biddulph " wrote in message ... You can try this: A1 : 01 Oct 07 A2 : 31 Dec 08 A3 : =DATEDIF(A1,A2,"YD"), 91 DAYS or A3 : =DATEDIF(A1,A2,"D"), 457 DAYS If you want more details, check out this thread. David Biddulph & Claude Jerry gave a long explanation on DateDIF function. http://www.microsoft.com/office/comm...2fsettings.xml "Malik" wrote: Hi, how do I subtract the dates? I have a date in one cell and a date in another. i wish to know the difference with respect to the number of days between the two dates. wt formula shud b used in the next cell? Simply applying the formula =A1-A2 gives me an absurd date in A3? i need the no of days. thx for help. |
Subtracting Dates
thnx everyone
"David Biddulph" wrote: Yes, but you don't need DATEDIF if you just want a number of days. =A2-A1 is fine, but the answer needs to be formatted as Number or General, not as a date. -- David Biddulph " wrote in message ... You can try this: A1 : 01 Oct 07 A2 : 31 Dec 08 A3 : =DATEDIF(A1,A2,"YD"), 91 DAYS or A3 : =DATEDIF(A1,A2,"D"), 457 DAYS If you want more details, check out this thread. David Biddulph & Claude Jerry gave a long explanation on DateDIF function. http://www.microsoft.com/office/comm...2fsettings.xml "Malik" wrote: Hi, how do I subtract the dates? I have a date in one cell and a date in another. i wish to know the difference with respect to the number of days between the two dates. wt formula shud b used in the next cell? Simply applying the formula =A1-A2 gives me an absurd date in A3? i need the no of days. thx for help. |
All times are GMT +1. The time now is 12:26 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com