cwilliams96
Board Regular
- Joined
- Jul 27, 2003
- Messages
- 186
Hi
I have a macro that places formula in a certain cells part way down a sheet/ The row number is defined by a variable.
Here is an example of one line of code that places a formula in column C at row i (i is a count of rows from another sheet)
Range("C" & i + 10).Formula = "=IF(LEFT('B1 - Del'!G2,1)=""T"",LEFT('B1 - Del'!G2,14),LEFT('B1 - Del'!G2,16))"
Once this and other formulas are in place I then want to select that range of formulas and copy them down a set number of rows. Say for example copying the formulas in Columns C,D,E at row i, down a set number of rows
The difficulty I am having is telling excel where the cells are I want to copy by using Range
For example if row 11 had the formulas in, I could use the below. But I need the row number to be the value in the variable i
Range("C11:E11").Select
Any help would be aprpeciated
Thanks
Chris
I have a macro that places formula in a certain cells part way down a sheet/ The row number is defined by a variable.
Here is an example of one line of code that places a formula in column C at row i (i is a count of rows from another sheet)
Range("C" & i + 10).Formula = "=IF(LEFT('B1 - Del'!G2,1)=""T"",LEFT('B1 - Del'!G2,14),LEFT('B1 - Del'!G2,16))"
Once this and other formulas are in place I then want to select that range of formulas and copy them down a set number of rows. Say for example copying the formulas in Columns C,D,E at row i, down a set number of rows
The difficulty I am having is telling excel where the cells are I want to copy by using Range
For example if row 11 had the formulas in, I could use the below. But I need the row number to be the value in the variable i
Range("C11:E11").Select
Any help would be aprpeciated
Thanks
Chris