Evening peeps,
I have been trying to figure out what is wrong with my code for the past 4 weeks and have got no closer to fixing it. basically the workbook that i have created is a way of me keeping track of the time that I work but from time to time I tweak the master workbook and then use a macro to copy in the times from the old workbook. If I use .value then it copies it across with no trouble, but if I use the the .formula I have a run-time error '1004': Application-defined or object-defined error. any pointer or help greatly received as i' really struggling.
The code in question is:
Thank You in advance
Andy
I have been trying to figure out what is wrong with my code for the past 4 weeks and have got no closer to fixing it. basically the workbook that i have created is a way of me keeping track of the time that I work but from time to time I tweak the master workbook and then use a macro to copy in the times from the old workbook. If I use .value then it copies it across with no trouble, but if I use the the .formula I have a run-time error '1004': Application-defined or object-defined error. any pointer or help greatly received as i' really struggling.
The code in question is:
Code:
For x = 4 To 6
For y = 4 To 402
If Workbooks("old.xlsm").Sheets("Flexi Planner").Cells(y, x).Value <> "" Then
Workbooks(planner).Sheets("Flexi Planner").Cells(y, x).Formula = Workbooks("old.xlsm").Sheets("Flexi Planner").Cells(y, x).Formula
End If
Next y
Next x
Thank You in advance
Andy
Last edited: