G
Guest
Hi, this is my code, but i got a runtime error of 1004 when i run below:
Can someone help pls?
Workbooks.Open ("H:\My WorkStation\PRCD\PRCDTEMP.XLS")
Windows("PRCDTEMP.XLS").Activate
Range("A2").Select
Range(Selection, ActiveCell.SpecialCells(xlLastCell)).Select
Selection.Copy
Windows("PRCDTEMP.XLS").Close
Workbooks.Open ("H:\My WorkStation\PRCD\" + strName)
Windows(strName).Activate
With Worksheets("Sheet1").Range("B65536").End(xlUp).Offset(1, 0)
..PasteSpecial xlValues ....> it stops here! cannot paste due to range class
failure...
End With
Application.CutCopyMode = False
Can someone help pls?
Workbooks.Open ("H:\My WorkStation\PRCD\PRCDTEMP.XLS")
Windows("PRCDTEMP.XLS").Activate
Range("A2").Select
Range(Selection, ActiveCell.SpecialCells(xlLastCell)).Select
Selection.Copy
Windows("PRCDTEMP.XLS").Close
Workbooks.Open ("H:\My WorkStation\PRCD\" + strName)
Windows(strName).Activate
With Worksheets("Sheet1").Range("B65536").End(xlUp).Offset(1, 0)
..PasteSpecial xlValues ....> it stops here! cannot paste due to range class
failure...
End With
Application.CutCopyMode = False