View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
JP[_4_] JP[_4_] is offline
external usenet poster
 
Posts: 897
Default How put Array in VBA

Sub del()
For Each c In Sheets("Data").Column("A")
If UBound(Filter(Array("XX", "YY", "SS", "ZZ"), c.Value)) = -1 Then
c.EntireRow.Delete
End If
Next
End Sub



On Nov 12, 10:33*am, K wrote:
Hi all, how can I make array work in below macro

Sub del()
For Each c In Sheets("Data").Column("A")
If c.Value < Array("XX", "YY", "SS", "ZZ") Then
c.EntireRow.Delete
End If
Next
End Sub

please can any friend can help