Private Sub CommandButton1_Click()
Dim sDate As Date, eDate As Date
With Me
sDate = CDate(.TextBox1.Value)
eDate = CDate(.TextBox2.Value)
End With
With Sheet1.Range("A2:A" & (Year(eDate) - Year(sDate) + 2))
.Formula = "=" & Year(sDate) & "+Row(A1)-1"
.Value = .Value
End With
End Sub