/ Published in: VB.NET

I don\\\'t know if exist a easier way to do this. For me, works fine. =)
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
Sub ClearArray(ByVal lst As ArrayList) Dim flag As Boolean = False For x As Integer = 0 To lst.Count - 1 If x > lst.Count - 1 Then flag = True End If If x = lst.Count Then Exit For End If If String.IsNullOrEmpty(lst(x)) Or Regex.IsMatch(lst(x), "[\s]+") Then lst.RemoveAt(x) If Not flag Then x = x - 1 Else x = x + 1 End If End If Next End Sub
Comments
