Put zero in cell C3 and then this formula in C4:

Formula: copy to clipboard
=SUM(A$4:A4)


Then copy this down to C11.

Then put this formula in a cell in column D (it doesn't matter which row - I put it in D11 for testing):

Formula: copy to clipboard
=IF(COLUMNS($D:D)>40,"",INDEX($B$4:$B$11,MATCH(COLUMNS($D:D)-0.1,$C$3:$C$11)))


Then copy this across to column AQ or beyond. Then you can just change your numbers in column A for a different display.

Hope this helps.

Pete