View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
poppy poppy is offline
external usenet poster
 
Posts: 1
Default Autofill Destination

Hi

I am trying to fill a number of cells with months up to the curren
month without having to hardcode the months. My problem is in the re
line. I would appreciate all your help.


Code
-------------------
lastrow = Cells(Rows.Count, "A").End(xlUp).Row
lastrow = lastrow + 3

For i = 2 To 2
For j = lastrow To lastrow
With Cells((j), (i))
.FormulaR1C1 = "Jan"
Cells(j, i).Select
Selection.AutoFill Destination:=Range("B14:H14"), Type:=xlFillDefault
End With
Next
Nex
-------------------


Kind regard

--
Message posted from http://www.ExcelForum.com