How do I change just the year component of a date using Excel formulas?
example: 12/31/07 --> 12/31/11
使用(例如)
=DATE(YEAR(A1)+5,MONTH(A1),DAY(A1))
一般方法:
=DATE(2011, MONTH(A1), DAY(A1))
我有同样的问题,但只是突出显示日期,然后在主页功能区上查找和选择,选择替换并键入2010年(我想要更改的年份)和2013年(我想要更改的年份)在查找中什么/替换什么框并单击全部替换它改变了所有日期。
假设你在单元格A1中有12/31/07
=DATE(YEAR(A1)+4, MONTH(A1), DAY(A1))
Int(A1)时间部分是小数部分
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.