Formatted Table Running Total  Custom Function

I have shared a running total formula for a formatted table many years ago. Here is a better solution that I have converted into a custom function.

My old post (6 years ago) can be found below.

Here is a more elegant solution.

This uses the SUM and INDEX functions together.

The INDEX function returns a reference to the first cell of the column.

The @ with the column then refers to the current row in the column.

The SUM adds up between the two references.

The formatted table automatically copies the formula down the column.

Custom Function

To simplify the process a custom function can be used. Here is the LAMBDA test formula.

=LAMBDA(tblCol,SUM(INDEX(tblCol,1):@tblCol))([Amount])

Here is the range name definition.

Here is the custom function is action.

This custom function will work with a normal range but you need to copy the formula down.

For a normal range you would use the SCAN and LAMBDA functions to create a Spill range.

Please note: I reserve the right to delete comments that are offensive or off-topic.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

3 thoughts on “Formatted Table Running Total  Custom Function

  1. When you say…
    “For a normal range you would use the SCAN and LAMBDA functions to create a Spill range.”
    what do you mean by “normal range”? Is that when you specify the range by its address? If so, are you suggesting that you cannot use SCAN on tables? This SCAN formula worked for me on your data when it was set up as a table…
    =SCAN(0,Table1[Amount],SUM)