Copy data from multiple columns and populate it in another sheet in one column,,

  • Thread starter Thread starter QuickLearner
  • Start date Start date
Q

QuickLearner

Hi guys
I working on a Bookeeping spreadsheet.
I need a bit of help.
I have three sheets
"CustomerList" with CustomerID in A column like C1,C2,C3....
SuppliersList" SupplierID in A like S1,S2,S3...and
"ExpensesList" ExpenseID in A like E1,E2,E3....

I want data (IDs) from all three sheets and populate it in another Sheet
called TrialBalance..
like
Column A
C1
C2
C3
S1
S2
S3
E1
E2
E3

Any tips here please.. (doesn't have to be in order and no duplicates)

thanks
Thanks
Rachid
 
thanks Jacob Sakoria
Found one of your answer in another ng.

After modifying the macro below a bit it is working for me. THANKS

Sub AutofilterTwoRanges()
Dim ws1 As Worksheet, ws2 As Worksheet, ws As Worksheet, lngRow As Long
Set ws1 = Sheet3
Set ws2 = Sheet12
Set ws = Sheet18

ws1.Columns(1).AdvancedFilter Action:=xlFilterCopy, _
CopyToRange:=ws.Range("A1"), Unique:=True
lngRow = ws.Cells(Rows.Count, "A").End(xlUp).Row + 1
ws2.Columns(1).AdvancedFilter Action:=xlFilterCopy, _
CopyToRange:=ws.Range("A" & lngRow), Unique:=True
ws.Rows(lngRow).Delete
ws.Columns(1).Sort Key1:=Range("A2"), Order1:=xlAscending, header:=xlYes
End Sub

Rachid
 
Back
Top