Hi,
I am trying to a column data from one sheet to other workbook which is already saved at the other location.
but I am able to open the workbook but while pasting the data it is giving me object error which I am not able to figure out.
I am attaching the sample files I am trying to copy data from Mail_file column F2:F15 to Base File next blank column in row 2
Mail_File.xlsmBase File.xlsx
Please help.
Sub CopyPaste()
Sheet1.Activate
Sheet1.Range("F2:F15").Copy
Workbooks.Open ("C:\Users\Vipin\Desktop\BAse File.xlsx")
With ActiveSheet
LastCol = .Cells(2, .Columns.Count).End(xlToLeft).Column + 1
End With
Sheet1.Cells(2, LastCol).PasteSpecial xlAllValues
Application.CutCopyMode = False
End Sub
Bookmarks