The Excel Pduration function uses the following calculation to calculate the number of periods required for an investment to reach a specified value:
where,
The Excel Pduration function calculates the number of periods required for an investment to reach a specified future value.
Note: the Pduration function was only introduced in Excel 2013 and so is not available in earlier versions of Excel.
The syntax of the function is:
Where the arguments are as follows:
rate    The interest rate, per period. 
pv    The present value of the investment. 
fv    The required future value of the investment. 
The following spreadsheet shows the Excel Pduration function used to calculate the number of years required for an investment of $10,000, earning interest of 4% per year, to reach a value of $15,000.
Formula:
 Result:

With these parameters, the Excel Pduration function returns the value 10.33803507.
I.e. it would take 10.34 years for an investment of $10,000, earning interest of 4% per year, to reach a value of $15,000.
Further examples of the Excel Pduration function are provided on the Microsoft Office website.
If you get an error from the Pduration function, this is likely to be one of the following:
#NUM!    Occurs if any of the supplied arguments are zero or negative. 
#VALUE!    Occurs if any of the supplied arguments are nonnumeric. 