Delete multiple, atau delete data sesuai yang di inginkan banyak dengan per klik, sbb scriptnya :
untuk di form tombol deletenya,
perhatikan yang warna merah, itu untuk menunjuk sheet cell nya ya.
Private Sub Cmd_Del_Click()
Dim sh As Worksheet
Set sh = ThisWorkbook.Worksheets("Sheet1")
Dim i As Long
For i = Me.LB_NamaKode.ListCount - 1 To 0 Step -1
If Me.LB_NamaKode.Selected(i) = True Then
sh.Range("A" & i + 2 & ":B" & i + 2).Select
Selection.Delete
End If
Next i
Call UserForm_Initialize
End Sub
Private Sub UserForm_Initialize()
On Error Resume Next
With Me.LB_ZoneRegion
.Clear
.ColumnCount = 2
.ColumnHeads = True
.ColumnWidths = "40;50"
.RowSource = "ZoneRegion"
.MultiSelect = fmMultiSelectMulti
End With
End Sub