I have cell B3 configured with date format and the table as follows
What I want to do is that, having the cell format as date, if the month in cell A2 is JANUARY, B2 shows 2023 (that is, it adds 1 to the current year, but instead it returns 1/14/1900 and I don't know how to fix it, what can I do?
=IF(A2="JANUARY";TEXT(TODAY();"yyyy") 1;TEXT(TODAY();"yyyy"))
CodePudding user response:
You seem not to know about the EDATE()
Excel function, which adds one or several months to a start date, as you can see here:
Once you have that result, you can use the =YEAR()
function in order to find the year of the date.