=DATE(A1,B1,C1)
Book3 | ||||||
---|---|---|---|---|---|---|
A | B | C | D | |||
1 | 2021 | 12 | 11 | 11/12/2021 | ||
2 | 2022 | 8 | 5 | 05/08/2022 | ||
3 | 2015 | 3 | 7 | 07/03/2015 | ||
4 | 2022 | 2 | 1 | 01/02/2022 | ||
5 | 1945 | 21 | 6 | 06/09/1946 | ||
6 | 1944 | 25 | 4 | 04/01/1946 | ||
7 | 1986 | 1 | 12 | 12/01/1986 | ||
8 | 3001 | 5 | 10 | 10/05/3001 | ||
9 | 3230 | 9 | 8 | 08/09/3230 | ||
Sheet1 |
Cell Formulas | ||
---|---|---|
Range | Formula | |
D1:D9 | D1 | =DATE(A1,B1,C1) |
=DATE(Jul!F8,MONTH(Jul!H1),DAY(Jul!F7))
The answer seems to be that I had the cell formatted wrong (changed it to General) where the year is entered and also had to remove the YEAR function.OK, since you are entering in the year only, but the MONTH and DATE are coming from another date (which was not clear from your original post), you would just use:
Excel Formula:=DATE(Jul!F8,MONTH(Jul!H1),DAY(Jul!F7))
Note: This all makes more sense when you understand how dates work in Excel.
Dates are really just numbers, with special date formats applied to them.
The number is just the number of days since 1/0/1900. You can see this easily by entering any date into Excel, and changing the format of that cell to "General".
This number is how Excel see dates.
So, if you enter the number 2023 in a cell, and then change it to a date format, you can see it represents the date: 7/15/1905.
That is why when you apply the YEAR function to that value, it returns 1905.
You do NOT want the year value from that date, you want to use that number, straight up, as the year. So you would not apply the YEAR function to it.
Make sense?
Yep, just like I said.The answer seems to be that I had the cell formatted wrong (changed it to General) where the year is entered and also had to remove the YEAR function.
But do you understand why you had to do this?Removing YEAR was a help, thanks...
Note: This all makes more sense when you understand how dates work in Excel.
Dates are really just numbers, with special date formats applied to them.
The number is just the number of days since 1/0/1900. You can see this easily by entering any date into Excel, and changing the format of that cell to "General".
This number is how Excel see dates.
So, if you enter the number 2023 in a cell, and then change it to a date format, you can see it represents the date: 7/15/1905.
That is why when you apply the YEAR function to that value, it returns 1905.
You do NOT want the year value from that date, you want to use that number, straight up, as the year. So you would not apply the YEAR function to it.