Dim Num1, Num2, TotalNum comme EntierSi TextBox1.Text> Rien Puis
Si Textbox2.Text> Rien Puis
Essayer
Num1.Focus ()
Num1 = Integer.Parse (TextBox1.Text)
Num2.Focus ()
Num2 = Integer.Parse (Textbox2.Text)
TotalNum = Num1 + Num2
Label1.Text = TotalNum.ToString ()
Catch
MessageBox.Show ("Un certain nombre valide est nécessaire»)
Essayez de Fin
Autre
MessageBox.Show ("Un certain nombre est nécessaire dans le second champ")
Retour
Autre
MessageBox.Show ("Un certain nombre est nécessaire dans le premier champ")
Retour
Fin si