The Betainv function is the inverse of the Excel Betadist function.
I.e. for a supplied probability, the Betainv function returns the value of x such that:
In Excel 2010, the Betainv function has been replaced by the Beta.Inv function, which has improved accuracy.
Although it has been replaced, the Betainv function is still available in current versions of Excel (stored in the list of compatibility functions), to allow compatibility with earlier versions of Excel.
However, the Betainv function may not be available in future versions of Excel, so it is advised that you use the Beta.Inv function if possible.
The Excel BETAINV function uses an iterative procedure to calculate the inverse of the cumulative beta probability density function for a supplied probability.
The syntax of the function is:
Where the function arguments are listed in the table below:
probability    The probability of the Beta distribution, for which you want to find the value of x. 
alpha    A parameter of the distribution (must be > 0). 
beta    A parameter of the distribution (must be > 0). 
[A]   
An optional argument which gives the lower bound of the interval of x. (If omitted, [A] takes the default value 0). 
[B]   
An optional argument which gives the upper bound of the interval of x. (If omitted, [B] takes the default value 1). 
Note that, if the arguments [A] and [B] are set to 0 and 1 respectively, the calculation becomes the Inverse Standard Cumulative Beta Distribution.
The charts below show the Cumulative Beta Distribution and the Inverse Cumulative Beta Distribution, with the parameter alpha set to 4 and the parameter beta set to 5.
The interval of x is set to [0, 1], which makes this the Standard Cumulative Beta Distribution.
Standard Cumulative Beta Distribution Function with α = 4 and β = 5 
Inverse Standard Cumulative Beta Distribution with α = 4 and β = 5 
If you want to use Excel to calculate the value of the Inverse Cumulative Beta Distribution for the probability 0.2, this can be done with the Betainv function, as follows:
This gives the result 0.303225845.
Note that, in the above example, the arguments [A] and [B] have been supplied to the functions as the values 0 and 1. However, these values could have been omitted from the function, as their values, if omitted, default to 0 and 1.
For further details and examples of the Excel Betainv function, see the Microsoft Office website.
If you get an error from the Excel Betainv function this is likely to be one of the following:
#NUM!   
Occurs if either:

#VALUE!    Occurs if any of the supplied arguments are nonnumeric. 