Private Sub CommandButton2_Click()
If TextBox1 = "" Or TextBox2 = "" Then MsgBox "Manque d'information": Exit Sub
With Sheets("Site 1")
bas = .[B65000].End(xlUp).Row + 1 'derniere ligne+1
.Cells(bas, 2) = Me.TextBox1.Text
.Cells(bas, 3) = Me.ListBox1.Text
.Cells(bas, 4) = Me.ListBox2.Text
.Cells(bas, 5) = Me.TextBox2.Text
End With
Unload Me
End Sub
Private Sub CommandButton3_Click()
'suppression
lig = Application.Match(Val(TextBox1), Sheets("Site 1").[B1:B65000], 0)
If IsNumeric(lig) Then
If MsgBox("Confimez Vous la suppression", vbExclamation + vbOKCancel, "SUPPRESSION") = vbOK Then
Sheets("Site 1").Rows(lig).Delete
End If
End If
End Sub