Jun 12, 2009

I've written the following code. It calculates the future value of required minimum distributions for traditional IRAs. When I enter the function in excel, it drops the last argument. I've tried changing the order of the arguments, and it always drops the last one. The arguments are : marginalTax (marginal tax rate), r (expected return on investment), t (time), begAge (beginning age), RDT (as range -- required distribution table; looks up the percentage required at each age), IRAValueat70 (calcualtes the value of the IRA at 70 years of age)

Function RMD(r As Double, marginalTax As Double, begAge As Integer, t As Integer, RDT As Range, IRAValueat70 As Long)

age = begAge

endAge = begAge + t

Dim holder As Long

Dim RMDnow As Long

Dim RMDall As Long

hat = 70

If endAge < 69 Then

Else

If begAge <= 69 Then

Do While hat < (endAge)

RMDnow = (IRAValue / (Application.VLookup(age, RDT, 2, False)))

RMDnow = (1 - marginalTax) * RMDnow...........................

View 2 Replies
View Related