ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Formula for converting xx/xx/xxxx dates to a number between 1 and (https://www.excelbanter.com/excel-worksheet-functions/240224-formula-converting-xx-xx-xxxx-dates-number-between-1-a.html)

Rodney Reed

Formula for converting xx/xx/xxxx dates to a number between 1 and
 
I need an Excel formula to convert a date (mm/dd/yyyy) to a serial number,
i.e. January 1st = 001, 1st February = 032, 31st and so on to December 31st =
365 . The serial number needs to reset to 001 on Jan 1st of each new year.

Is there a quick way to convert any given date from any given year to this
3-digit day number?

Thanks in advance,
Rodney


Jacob Skaria

Formula for converting xx/xx/xxxx dates to a number between 1 and
 
If the date is in excel date format try the below formula with a date in cell
A1

'as text
=TEXT(A1-DATE(YEAR(A1),1,1)+1,"000")

as number
=A1-DATE(YEAR(A1),1,1)+1

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


"Rodney Reed" wrote:

I need an Excel formula to convert a date (mm/dd/yyyy) to a serial number,
i.e. January 1st = 001, 1st February = 032, 31st and so on to December 31st =
365 . The serial number needs to reset to 001 on Jan 1st of each new year.

Is there a quick way to convert any given date from any given year to this
3-digit day number?

Thanks in advance,
Rodney


Rick Rothstein

Formula for converting xx/xx/xxxx dates to a number between 1 and
 
You can save a mathematical operation like this...

=A1-DATE(YEAR(A1),1,0)

Note to OP... you will probably have to format the cells as General.

--
Rick (MVP - Excel)


"Jacob Skaria" wrote in message
...
If the date is in excel date format try the below formula with a date in
cell
A1

'as text
=TEXT(A1-DATE(YEAR(A1),1,1)+1,"000")

as number
=A1-DATE(YEAR(A1),1,1)+1

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


"Rodney Reed" wrote:

I need an Excel formula to convert a date (mm/dd/yyyy) to a serial
number,
i.e. January 1st = 001, 1st February = 032, 31st and so on to December
31st =
365 . The serial number needs to reset to 001 on Jan 1st of each new
year.

Is there a quick way to convert any given date from any given year to
this
3-digit day number?

Thanks in advance,
Rodney




All times are GMT +1. The time now is 05:40 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com