Option Explicit
Private Sub cmdUp_Click()
Dim arrItems As Variant
Dim cnt As Long
Dim idx As Long
Dim idxTop As Long
With ListBox1
ReDim arrIndexItems(1 To .ListCount)
ReDim arrItems(1 To .ListCount)
For idx = .ListCount - 1 To 0 Step -1
If .Selected(idx) Then
idxTop = idx
cnt = cnt + 1
arrItems(cnt) = .List(idx, 0)
.RemoveItem idx
End If
Next idx
End With
If idxTop <> 0 Then
ReDim Preserve arrItems(1 To cnt)
For idx = 1 To cnt
With ListBox1
.AddItem arrItems(idx), idxTop - 1
End With
Next idx
End If
End Sub
Private Sub UserForm_Initialize()
Dim arr As Variant
arr = Evaluate("""Item""&ROW(1:20)")
With ListBox1
.List = arr
.MultiSelect = fmMultiSelectExtended
End With
End Sub