Home |
Search |
Today's Posts |
#1
|
|||
|
|||
Formula to get a day of the year from a date
Hi,
Is there a way that I can get the day of the year returned in a cell when I enter a date in another cell. So if I enter 01/01/2005 in A1, I would like "2" to display in cell A2. I need this number for calculations. Thanks. Rob |
#2
|
|||
|
|||
I dispute that 1/1/2005 is the second day of the year
=A1-DATE(YEAR(A1),1,1)+1 if you really meant 2 just add 2 instead of 1 att the end Regards, Peo Sjoblom " wrote: Hi, Is there a way that I can get the day of the year returned in a cell when I enter a date in another cell. So if I enter 01/01/2005 in A1, I would like "2" to display in cell A2. I need this number for calculations. Thanks. Rob |
#3
|
|||
|
|||
try
=INT(a1-DATE(YEAR(a1),1,0)) -- Don Guillett SalesAid Software wrote in message oups.com... Hi, Is there a way that I can get the day of the year returned in a cell when I enter a date in another cell. So if I enter 01/01/2005 in A1, I would like "2" to display in cell A2. I need this number for calculations. Thanks. Rob |
#4
|
|||
|
|||
Thanks for the solution. Sorry, my mind was thinking one thing while
my fingers were typing something else - of course it is day 1!! Thanks again. Peo Sjoblom wrote: I dispute that 1/1/2005 is the second day of the year =A1-DATE(YEAR(A1),1,1)+1 if you really meant 2 just add 2 instead of 1 att the end Regards, Peo Sjoblom " wrote: Hi, Is there a way that I can get the day of the year returned in a cell when I enter a date in another cell. So if I enter 01/01/2005 in A1, I would like "2" to display in cell A2. I need this number for calculations. Thanks. Rob |
#5
|
|||
|
|||
Try this (I use this formula to establish a text based 3 digit day of the
week reference) =mid(TEXT(J2,"mmmm dd, yyyy"),6,2) This should give you just the day. Sir Metro |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Date formula | Excel Discussion (Misc queries) | |||
Formula to determine a future date based on criteria | Excel Worksheet Functions | |||
dynamic year to date formula | Excel Worksheet Functions | |||
Need help troubleshooting an array formula XLXP on Win2K | Excel Worksheet Functions | |||
How do I add a date formula to a cell but hide the contents with . | Excel Discussion (Misc queries) |