I have done a fair amount of searching about this and have yet to find a working solution...
Goal – to programmatically copy spreadsheets (in Excel 2007) from one workbook and paste them into a new one. These sheets contain hidden rows which should not be in the new one.
Problem - The hidden rows are showing in the new one.
I am working with existing code - originally in Excel 2003.
___________________________________________
Attempted fix 1
The "Selection.Copy" line produces this error:
"Run-time error '1004':
This command cannot be used on multiple selections."
__________________________________________________
Attempted fix 2
The "Selection.PasteSpecial ..." line produces this error:
"Run-time error '1004':
Application-defined or Object-defined error"
Note: I tried several versions of the above one including copying it as a picture.
___________________________________________
I am fairly new to VBA coding so any help would be greatly appreciated.
Bill
Bookmarks