![]() |
Leading the way in Microsoft Office Development |
| Home | | | Excel | | | Word | | | PowerPoint | | | Consultancy | | | Feedback | | | Contact |
| Microsoft Excel > Functions > Date and Time > YEARFRAC |
YEARFRAC(start_date, end_date [,basis]) |
| Returns the number of years as a decimal between two dates. |
| start_date | The starting date. | |
| end_date | The finishing date. | |
| basis | The type of day counting to use. 0 = US 30/360 1 = Actual/Actual 2 = Actual/360 3 = Actual/365 4 = European 30/360 |
| REMARKS |
| This function is only available if you have the Analysis ToolPak add-in installed. | ||
| All arguments are truncated to integers. | ||
| Dates may be entered as text strings within quotation marks, as serial numbers or as results of other formulas or functions. | ||
| If "start_date" or "end_date" are not valid dates, then #NUM! is returned. | ||
| If "start_date" can be a text string or a date serial number. | ||
| If "basis" < 0, then #NUM! is returned. | ||
| If "basis" > 4, then #NUM! is returned. | ||
| If "basis" is left blank, then 0 is used. |
| EXAMPLES |
|
| Functions - Y | Index - Y | Dates & Times | Office Online |
| Copyright © 2004-2007 Better Solutions Limited. All Rights Reserved. | Top |