# Referenceing a cell value in a formula

#### deanfran

##### Board Regular
I think this is a simple one, and I have seen the solution here before, but I have been unable to search it out.
Here is what I have
1. Have a COUNT value in a cell (counted the number of rows with values in them).
2. A formula that needs this value (sums another set of values in another column that has the same number of rows).

Example: the COUNT value is 12, and is located in cell G5. For simplicity sake I have a formula in cell I5 SUM(F1:F12). Instead of directly referencing F12, I want the formula to be SUM(F1:F(G5)).

Is this possible?

### Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.
Hi

=SUM(F1:INDEX(F:F,G5))

Perfect. Thank you very much. I have asked this before, but is there any type of quick reference guide to things like this? I have a couple Excel books, and a VBA book, but none of them reference this.

one more

=SUM(F1:INDIRECT("F"&G5))

Perfect. Thank you very much. I have asked this before, but is there any type of quick reference guide to things like this? I have a couple Excel books, and a VBA book, but none of them reference this.

I must admit I haven't seen this particular way of referencing in books (maybe because I am looking in the worng books though!). This style I learned on this forum (and others like it) a while ago. Always in the past I've considered this forum to be my "quick reference" if I have a problem.

"I must admit I haven't seen this particular way of referencing in books (maybe because I am looking in the worng books though!). This style I learned on this forum (and others like it) a while ago. Always in the past I've considered this forum to be my "quick reference" if I have a problem. "

Amen to that!

Replies
8
Views
188
Replies
9
Views
174
Replies
8
Views
353
Replies
1
Views
171
Replies
10
Views
569

1,211,679
Messages
6,103,245
Members
447,850
Latest member
thebuzzman15

### We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.

### Which adblocker are you using?

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

### Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

### Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back