'Query Question / VBA , Copy to Filtered Data (Noncontinuous) to other sheet / Union
I am beginner at VBA
This is my Raw data

And this is output what I want

I am trying Copy filtered data (Non Continuous Column B C D & G H ) to other sheet
And I tried this :
Sub AdvancedFilterCode()
Dim iRange As Range
Dim iCriteria As Range
Set iRange = Union(Sheets("Original").Range("B3:D17"), Sheets("Original").Range("G3:H17"))
Set iCriteria = Sheets("Original").Range("J4:J5")
iRange.AdvancedFilter Action:=xlFilterCopy, CriteriaRange:=iCriteria, _
CopyToRange:=Sheets("Target").Range("B4:f4"), Unique:=True
End Sub
======================================================
and I got error..
Could you tell me what's wrong with my query..?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
