hi,
I need to copy range A2:B upto last row from Source worksheet (SOA) and paste to last row to the destination (Worksheet) table1 and also do the same process from D2:Q upto last row.
hi,
I need to copy range A2:B upto last row from Source worksheet (SOA) and paste to last row to the destination (Worksheet) table1 and also do the same process from D2:Q upto last row.
Please Login or Register to view this content.
Surround your VBA code with CODE tags e.g.;
[CODE]your VBA code here[/CODE]
The # button in the forum editor will apply CODE tags around your selected text.
Thank you Alpha, works perfectly. Can you please add on more line to sort Column B.
Please Login or Register to view this content.
As a beginner starter :
PHP Code:
Sub Demo1()
Dim R&
With Sheet1.ListObjects(1)
R = .TotalsRowRange.Row
.Resize .Range.Resize(1 + .ListRows.Count + Sheet2.UsedRange.Rows.Count)
With Sheet2.UsedRange.Rows("2:" & Sheet2.UsedRange.Rows.Count).Columns
.Item("A:B").Copy Sheet1.Cells(R, 1)
.Item("C:Q").Copy Sheet1.Cells(R, 4)
End With
.Range.Sort .Range(1, 2), xlAscending, Header:=xlYes
End With
End Sub
Do you like it ? So thanks to click on bottom left star icon « ★ Add Reputation » !
Thank You Alpha, Excellent. As you have converted Column B into Date Format, now I don't need that additional Column C. I will amend the code. Solved..
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks