Protected Overloads Sub OnLeave(sender As Object, e As EventArgs) Handles txtValor1.Leave,
txtValor2.Leave, txtValor3.Leave, txtValor4.Leave
MyBase.OnLeave(e)
dim res As Integer = 0
Dim m As New Modelo
m.Valor1 = Int32.TryParse(txtValor1.Text, res)
m.Valor2 = Int32.TryParse(txtValor1.Text, res)
m.Valor3 = Int32.TryParse(txtValor1.Text, res)
m.Valor4 = Int32.TryParse(txtValor1.Text, res)
m.Resultado = Val(m.Valor1) + Val(m.Valor2) + Val(m.Valor3)
txtResultado.Text = m.Resultado
End Sub