I've been battling with this macro on and off. I've got it to work and it worked just fine until all of a sudden when I got a Run-time error
"'Test.xlsm' could not be found. Check the spelling of the file name, and verify that the file location is correct.
If you are tyring to open the file from your list of most recently used files, make sure that the file has not been renamed, moved, or deleted. "
I did not rename or move the file from it's location yet I'm getting this error. I'm lost on why all of a sudden this occurs.
Sub ImportData_Click()
' open the source workbook and select the source sheet
Workbooks.Open Filename:="Test.xlsm"
Sheets("Make").Select
' copy the source range
Sheets("Make").Range("A1:Z630").Select
Selection.Copy
' select current workbook and paste the values starting at A1
ThisWorkbook.Activate
Sheets("Make").Select
Sheets("Make").Range("A1:Z630").Select
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=False
' close the source workbook
Windows("Test.xlsm").Activate
ActiveWorkbook.Close
End Sub