PRIVATE SUB TestSub(L1 AS LISTBOX,L2 AS LISTBOX)
    Dim i, a As Integer
    Dim str As String
    a = L2.ListCount    
    Do While i <> a
          
      
        If L2.Selected(i) Then
            
            L1.AddItem L2.List(i)
            
            L2.RemoveItem i
            a = a - 1
            i = i - 1
            
        End If
        
        L2.Refresh
        i = i + 1
END SUB
在command2_clicK事件中 call testsub(L1,L2)
在command1_clicK事件中 call testsub(L2,L1)