AK_Caveman
New Member
- Joined
- Apr 12, 2018
- Messages
- 2
I am a complete noob to VBA. We have a macro that runs fine on Excel 2013 but gets a Run-time error on 2016. The part of the macro where it hangs up is trying to copy and paste merged cells. The error states "To do this, all merged cells need to be the same size." They are the same size. It appears to have no issues copying, just pasting into the new spreadsheet. Here is the code:
It errors on the last line.
Code:
Workbooks("rmgr-update.xlsm").Activate
Sheets("Sheet2").Select
Range("a1:a2").Copy
Workbooks(pasteFile).Activate
Sheets("Template").Select
Range("a1:a2").PasteSpecial Paste:=xlPasteValues
It errors on the last line.