tmd63
New Member
- Joined
- Feb 21, 2014
- Messages
- 40
- Office Version
- 2013
- 2003 or older
- Platform
- Windows
I am trying to copy from a workbook that has a single sheet called 'Lookup' to my local workbook using vba in excel2003 (for macros issue).
When I use the code below, I get the entire sheet data, but not the formula is a couple of columns.
How can I copy the formula as well as the data?
When I use the code below, I get the entire sheet data, but not the formula is a couple of columns.
Code:
Workbooks.Open ("http://******.com/Shared%20Documents/Lookup.xls")
LastRow = ActiveSheet.Cells.Find("*", , xlFormulas, xlPart, xlByRows, xlPrevious).Row
ActiveSheet.Range("A1:M" & LastRow).Select
Selection.Copy
Application.DisplayAlerts = False
ActiveWorkbook.Close
Worksheets("Lookup").Select
ActiveSheet.Range("A1").Select
Worksheets("Lookup").Paste
How can I copy the formula as well as the data?
Last edited: