I want to use the code below in 15 worksheets. The issue I have is if a user inserts a column after "I" which than that mess's up the formula (Range("m7:m166").Select) in the macro. If I used named ranges than I would need 15 names and 15 macros. Must be an easier way??? Less lengthy way???
Code:
Sub Ref1Machine()'
' Ref1Machine Macro
'
'
Application.ScreenUpdating = False
Range("RefMaster") = Range("e3")
' REFRESH_DATA Macro
ActiveWorkbook.RefreshAll
' Gets the machine in the cell above actual hours/$ and pastes them below
'
Range("D6:D85").Select
Application.CutCopyMode = False
Selection.Copy
ActiveWindow.SmallScroll Down:=-60
Range("e6").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Range("m7:m166").Select
Application.CutCopyMode = False
Selection.Copy
ActiveWindow.SmallScroll Down:=-144
Range("n7").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Range("E3").Select
Application.CutCopyMode = False
Application.ScreenUpdating = True
End Sub