I'm trying to set up a varable range to pass into the auto fill funtion. The range will vary depending on the number of months. The months start F1 and will vary from 1 to 12. In the example below June is the starting month (in cell F1) and I want to autofill the formula through december.
Range("F4").Select
ActiveCell.FormulaR1C1 = "=R[-2]C-R[-1]C"
Selection.AutoFill Destination:=Range("F4:L4"), Type:=xlFillDefault
Next month July will be in cell F1 and I will need to change the fill range to ("F4:K4")
any ideas?
Thanks,
Bill
Range("F4").Select
ActiveCell.FormulaR1C1 = "=R[-2]C-R[-1]C"
Selection.AutoFill Destination:=Range("F4:L4"), Type:=xlFillDefault
Next month July will be in cell F1 and I will need to change the fill range to ("F4:K4")
any ideas?
Thanks,
Bill