Jediantman
New Member
So I'm getting very frustrated with a macro I created which basically opens 14 individual sheets copies a selected range of data then pastes it to another. All was fine and working without problems until I had to include some hidden columns into the source data, which are also replicated in the destination. The problem I have is that on 2 out of the 14 source files when the range of cells to copy is selected it ignores the hidden columns so when it pastes it puts everything in the wrong place. The real frustration comes from the fact that the code I'm using is identical, all that changes is the file names.
The code that works is below:
[pre]
[/pre]
Any ideas are welcomed before I suffer an embolism...
The code that works is below:
[pre]
Code:
Workbooks.Open Filename:= _
"T:Aidan Spr2013 Tracker.xlsx" _
, ReadOnly:=True, Notify:=False
Sheets("Section 5").Select
Range("A23:CH130").Select
Selection.Copy
Windows("SPR13_Datamastermacro.xlsm").Activate
Sheets("Section5Master").Select
Range("A23").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
ActiveWindow.SmallScroll Down:=213
Range("A134").Select
The code that doesn't work properly:
Workbooks.Open Filename:= _
"T:Lewis Spr2013 Tracker.xlsx" _
, ReadOnly:=True, Notify:=False
Application.DisplayAlerts = True
Sheets("Section 5").Select
Range("A23:CH130").Select
Selection.Copy
Windows("SPR13_Datamastermacro.xlsm").Activate
Sheets("Section5Master").Select
Range("A689").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
ActiveWindow.SmallScroll Down:=231
Range("A790").Select
Any ideas are welcomed before I suffer an embolism...