Please look at my recorded macro below and tell me how I can change the lines 13 to 15 to be able use the macro even though the range length is different.
Thanks for your help.
1 Windows("JODA - Open AMR Service Requests.xlsx").Activate
2 Sheets("All").Select
3 Range("K2").Select
4 ActiveCell.FormulaR1C1 = "=TODAY()-RC[-3]"
5 Range("O2").Select
6 ActiveCell.FormulaR1C1 = "=RC[4]"
7 Range("P2").Select
8 ActiveCell.FormulaR1C1 = "=RC[4]"
9 Range("Q2").Select
10 ActiveCell.FormulaR1C1 = "=RC[4]"
11 Range("R2").Select
12 ActiveCell.FormulaR1C1 = "=RC[4]"
13 Range("K2:AA2").Select
14 Selection.AutoFill Destination:=Range("K2:AA5313"), Type:=xlFillDefault
15 Range("K2:AA5313").Select
16 Columns("K:K").Select
17 Selection.Copy
18 Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
19 :=False, Transpose:=False
20 Range("O2:R2").Select
21 Range(Selection, Selection.End(xlDown)).Select
22 Application.CutCopyMode = False
23 Selection.Copy
24 Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
25 :=False, Transpose:=False
26 Range("H2:I2").Select
27 Range(Selection, Selection.End(xlDown)).Select
28 Application.CutCopyMode = False
29 ' Pause so you can inspect results...
30 MsgBox "All done, click me to continue...", vbMsgBoxSetForeground
31 Windows("Macro_SR.xlsm").Activate
Bookmarks