Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi. I have a list of numbers in C26 through C36. Cell
C37 sums these. I need for the user to be able to add rows and have the summation cell change accordingly. This works unless the user inserts a row after the last row. Is there a way, through programming or otherwise, to make the formula change even in this situation? I do have a variable in my macro called "lastRow" that records the row number of the summation row (currently 37). Thanks, Mike. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi Mike,
I think the following formula entered on C37 should help you. =SUM($C$26:OFFSET(C26,-1,0)) I had seen this type of an formula used to a very similar question to your recently. I thought it was a good solution. Hopefully, it works for you too. Regards, Kevin "Mike" wrote in message ... Hi. I have a list of numbers in C26 through C36. Cell C37 sums these. I need for the user to be able to add rows and have the summation cell change accordingly. This works unless the user inserts a row after the last row. Is there a way, through programming or otherwise, to make the formula change even in this situation? I do have a variable in my macro called "lastRow" that records the row number of the summation row (currently 37). Thanks, Mike. |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I think Kevin meant:
=SUM($C$26:OFFSET(C37,-1,0)) Kevin Stecyk wrote: Hi Mike, I think the following formula entered on C37 should help you. =SUM($C$26:OFFSET(C26,-1,0)) I had seen this type of an formula used to a very similar question to your recently. I thought it was a good solution. Hopefully, it works for you too. Regards, Kevin "Mike" wrote in message ... Hi. I have a list of numbers in C26 through C36. Cell C37 sums these. I need for the user to be able to add rows and have the summation cell change accordingly. This works unless the user inserts a row after the last row. Is there a way, through programming or otherwise, to make the formula change even in this situation? I do have a variable in my macro called "lastRow" that records the row number of the summation row (currently 37). Thanks, Mike. -- Dave Peterson |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Dave,
Thank you! Kevin "Dave Peterson" wrote in message ... I think Kevin meant: =SUM($C$26:OFFSET(C37,-1,0)) |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
problem with Summation | Excel Discussion (Misc queries) | |||
Summation | Excel Discussion (Misc queries) | |||
summation | Excel Worksheet Functions | |||
conditional summation | Excel Discussion (Misc queries) | |||
Summation from a to b | Excel Worksheet Functions |