Private Sub CommandButton1_Click()
'Si Text box2 n'est pas vide
If Trim(TextBox2.Text) <> "" Then
'Si textbox2 est contenu dans TextBox1
If InStr(1, TextBox1.Text, TextBox2.Text) > 0 Then
MsgBox "Ce texte existe déjà", vbExclamation
Else
TextBox1.Text = TextBox1.Text & vbLf & TextBox2.Text
End If
'Vider TextBox2
TextBox2.Text = ""
End If
End Sub