08-23-2013, 12:18 PM
Try this...
Code:
Qtn = ("a;b;c;d")
Arr = Split(Qtn,";")
ItemToBeDeleted = "b"
Brr = ToDeleteEle( Arr , ItemToBeDeleted)
Function ToDeleteEle (Arr , ItemToBeDeleted)
For i = 0 to UBound(Arr)
If Arr(i) = ItemToBeDeleted Then
While i<UBound(Arr)
Arr(i) = Arr(i+1)
i=i+1
Wend
End If
Next
ReDim Preserve Arr(Ubound(Arr)-1)
ToDeleteEle = Arr
End Function