I need to know which is the fastest way to delete a specific element of an Array ...
This is my code:
ThanksCode:Private Sub Delete_Array_Item(ByRef lArray() As Long, ByVal lIndex As Long) Dim lCount As Long Dim x As Long lCount = UBound(lArray) If lIndex <= lCount And lIndex >= LBound(lArray) Then For x = lIndex To lCount - 1 lArray(x) = lArray(x + 1) Next ReDim Preserve lArray(lCount - 1) End If End Sub![]()





Reply With Quote