Fill down based on rows in region

  • Thread starter Thread starter ronber
  • Start date Start date
R

ronber

Suppose data in A1:F1 and in A1:Asome number

I want to fill code starting in E2 down to Esomenumber.

Suppose the formula is "=MyCode"

How do I go about doing that, given the number of rows may vary and I
want the code to adapt to the number of rows?

TIA
Ron
 
Ron

Dim LastRow As Long
LastRow = Range("A65536").End(xlUp).Row
Range("E2:E" & LastRow).Formula = "=MyCode"

Regards

Trevor
 
Back
Top