Hi I am writing a code that selects data all the data from one workbook (except header) and pastes it to a master file. I got the slect part right, but I am having difficulty figuring out how to write it to locate the last row where there is no data and pasting the selection there.
Code:
Sub AppendMaster()
Workbooks.Add
Workbooks.Open Filename:=ThisWorkbook.Path & "\Minor.csv"
Dim rng As Range
Set rng = ActiveSheet.UsedRange
Set rng = rng.Offset(1).Resize(rng.Rows.Count - 1)
rng.Select
Selection.Copy
Workbooks.Open Filename:=ThisWorkbook.Path & "\Master.csv"
Windows("Master.csv").Activate
' ??????????????????????? ActiveSheet.Paste
'
End Sub