Home |
Search |
Today's Posts |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
You don't always have to loop. You can have your code behave like you do when
you select a bunch of cells and type the formula once and then hit ctrl-enter to fill all the cells in the selection. Option Explicit Sub testme() Dim LastRow As Long With ActiveSheet LastRow = .Cells(.Rows.Count, "I").End(xlUp).Row .Range("L2:L" & LastRow).Formula = "=j2/100" .Range("M2:M" & LastRow).Formula = "=e2*l2" End With End Sub Rob Moore wrote: I am trying to add a formula to a macro and don't know where to being. Beginning on row 2 and continuing on I have a number in Column J. In column L I would like to have a formula that is "Column J/100" then in column m have a second formula that is "Column E * Column L". The number of rows wil vary but will always begin with row 2 and column I will always contain data. Any help would be greatly appreciated. Thanks -- Dave Peterson |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Regression Leverage Formula (Jerry W. Lewis or Mike Middleton)already have DFITS formula | Excel Worksheet Functions | |||
Excel 2002 Formula: Urgent Conditional Formula Required Right Away - if possible | Excel Discussion (Misc queries) | |||
Formula expected end of statement error, typing formula into cell as part of VBA macro | Excel Programming | |||
Lopp in column to find and select | Excel Programming | |||
Commenting custom formula fields/formula on formula editor | Excel Programming |