Greetings -
I am writing a report generator and am having difficultites adding a sum formula to the bottom of a range.
I have a range of data between H2:X23 (this will change each time the report is run). I can select the range where I need to drop in my formulas via variables...I just can't seem to figure out how to write the summing formulas that use the variables. This is where I am...
Range(Cells(RowNum + 1, 8), Cells(RowNum + 1, Columnsinsheet)).Select
Selection.FormulaR1C1 = "=SUM(R[-1]C:R[-1]C)"
I'm stuck on the R1C1 formula. Each column needs to sum from row 2 to RowNum. Can anyone please help?
>M
____________________
Mike
I am writing a report generator and am having difficultites adding a sum formula to the bottom of a range.
I have a range of data between H2:X23 (this will change each time the report is run). I can select the range where I need to drop in my formulas via variables...I just can't seem to figure out how to write the summing formulas that use the variables. This is where I am...
Range(Cells(RowNum + 1, 8), Cells(RowNum + 1, Columnsinsheet)).Select
Selection.FormulaR1C1 = "=SUM(R[-1]C:R[-1]C)"
I'm stuck on the R1C1 formula. Each column needs to sum from row 2 to RowNum. Can anyone please help?
>M
____________________
Mike