Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- For Each Cell in newRange
- Cell.EntireColumn.Delete
- Dim Cell As Range
- Dim Source As Range
- Set Source = Range(Cells(1, 1), Cells(1, Columns.Count))
- Dim strWords As Variant
- strWords = Array("Number", "First Name")
- For Each Cell In Source
- For i = UBound(strWords) To LBound(strWords) Step -1
- If InStr(UCase(Cell), UCase(strWords(i))) > 0 Then
- Cell.EntireColumn.Delete
- Next i
- Next
- End Sub
- If InStr(UCase(Cell), UCase(strWords(i))) > 0 Then
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement