ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Referencing cell numbers in a formula (https://www.excelbanter.com/excel-programming/399939-referencing-cell-numbers-formula.html)

willheld

Referencing cell numbers in a formula
 
How would you write a formula that looked up part of its cell restraints?

For instance €“ if you have a set of formulas like:

=SUM(Timesheet!C32:C396)
=SUM(Timesheet!D32:D396)
=SUM(Timesheet!E32:E396)
=SUM(Timesheet!H32:H396)/8
and so forth.

Where the Column designation stays the same but the beginning and ending
numbers change based off of what period I decide to look at.
Is it possible to write a formula that references the number portion of the
cell designations from a separate cell?

For instance:

=SUM(Timesheet!C{=A5):C{=A6})
=SUM(Timesheet!D{=A5): D{=A6})
=SUM(Timesheet!E{=A5):E{=A6})
=SUM(Timesheet!H{=A5):H{=A6})/8

I ran into this situation, just changed all the numbers to fit the periods I
was wanting to view from my continually growing data page but was wondering
if there was an easier method.

--
Bill H.

Tom Ogilvy

Referencing cell numbers in a formula
 
=SUM(Indirect("Timesheet!C" &A5":C"&A6))

--
Regards,
Tom Ogilvy



"willheld" wrote:

How would you write a formula that looked up part of its cell restraints?

For instance €“ if you have a set of formulas like:

=SUM(Timesheet!C32:C396)
=SUM(Timesheet!D32:D396)
=SUM(Timesheet!E32:E396)
=SUM(Timesheet!H32:H396)/8
and so forth.

Where the Column designation stays the same but the beginning and ending
numbers change based off of what period I decide to look at.
Is it possible to write a formula that references the number portion of the
cell designations from a separate cell?

For instance:

=SUM(Timesheet!C{=A5):C{=A6})
=SUM(Timesheet!D{=A5): D{=A6})
=SUM(Timesheet!E{=A5):E{=A6})
=SUM(Timesheet!H{=A5):H{=A6})/8

I ran into this situation, just changed all the numbers to fit the periods I
was wanting to view from my continually growing data page but was wondering
if there was an easier method.

--
Bill H.


willheld

Referencing cell numbers in a formula
 
This seems to work on the first cell but not on the second cell reference, I
recieve a formula error.


--
Bill H.


"Tom Ogilvy" wrote:

=SUM(Indirect("Timesheet!C" &A5":C"&A6))

--
Regards,
Tom Ogilvy



"willheld" wrote:

How would you write a formula that looked up part of its cell restraints?

For instance €“ if you have a set of formulas like:

=SUM(Timesheet!C32:C396)
=SUM(Timesheet!D32:D396)
=SUM(Timesheet!E32:E396)
=SUM(Timesheet!H32:H396)/8
and so forth.

Where the Column designation stays the same but the beginning and ending
numbers change based off of what period I decide to look at.
Is it possible to write a formula that references the number portion of the
cell designations from a separate cell?

For instance:

=SUM(Timesheet!C{=A5):C{=A6})
=SUM(Timesheet!D{=A5): D{=A6})
=SUM(Timesheet!E{=A5):E{=A6})
=SUM(Timesheet!H{=A5):H{=A6})/8

I ran into this situation, just changed all the numbers to fit the periods I
was wanting to view from my continually growing data page but was wondering
if there was an easier method.

--
Bill H.


Tom Ogilvy

Referencing cell numbers in a formula
 
if you copy it down, the A6 will change to A7 as an example. If A7 doesn't
have an integer that is a valid formula reference, then you will have to fix
the cell you are referencing or correct the data contained in the cell
referenced.

I gave you an example of how to do it - you have to implement it.

--
Regards,
Tom Ogilvy


"willheld" wrote:

This seems to work on the first cell but not on the second cell reference, I
recieve a formula error.


--
Bill H.


"Tom Ogilvy" wrote:

=SUM(Indirect("Timesheet!C" &A5":C"&A6))

--
Regards,
Tom Ogilvy



"willheld" wrote:

How would you write a formula that looked up part of its cell restraints?

For instance €“ if you have a set of formulas like:

=SUM(Timesheet!C32:C396)
=SUM(Timesheet!D32:D396)
=SUM(Timesheet!E32:E396)
=SUM(Timesheet!H32:H396)/8
and so forth.

Where the Column designation stays the same but the beginning and ending
numbers change based off of what period I decide to look at.
Is it possible to write a formula that references the number portion of the
cell designations from a separate cell?

For instance:

=SUM(Timesheet!C{=A5):C{=A6})
=SUM(Timesheet!D{=A5): D{=A6})
=SUM(Timesheet!E{=A5):E{=A6})
=SUM(Timesheet!H{=A5):H{=A6})/8

I ran into this situation, just changed all the numbers to fit the periods I
was wanting to view from my continually growing data page but was wondering
if there was an easier method.

--
Bill H.



All times are GMT +1. The time now is 12:52 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com