rkaufmann87 wrote:
Hi Barry,
Thanks for posting the example, not quite though. In your sample Table A is transferring all the totals to Table B. What I'd like is as I enter the data in the columns in Table A Table B then picks up the
latest update in a single cell. For example lets say Table A's Column A is May 1 and the total is 45, let's say that sum is placed in A15. Table B automatically picks up A15 from Table A and makes a duplicate in Table B cell A1, then the next day Table A's Column B is May 2 and the total is 90 (cell B15), then Table B senses the latest total is 90 and enters that in cell A1 again. Is this possible?
Here's another go.
Table 1 has a second Header row added (row 2) Cells in this row contain the formula
=IF(A1=MAX($1:1),COLUMN(),"")
Which returns the column number of the cell in row 1 containing the latest date. (4) This number is used by Table 2 to determine the column from which to return the total in the bottom (footer) row. (see below)
A1 in Table 2 and Table 3 contain the same formula:
=MAX(Table 1 :: $1:1)
This returns the latest date from row 1 of Table 1.
A2 in Table 2 and Table 3 contain formulas that return the value in the bottom cell of the column containing the latest date in row 1.
Table 2: =OFFSET(Table 1 :: $A$1,ROWS('May 1, 2010')-1,MAX(Table 1 :: $2:2)-1)
Table 3: =OFFSET(Table 1 :: $A$1,ROWS('May 1, 2010')-1,COUNT(Table 1 :: $1:1)-1)
Both use the same base ($A$1) and the same row offset (ROWS('May 1, 2010')-1) to reach the bottom row of Table 1.
Table 2 uses the maximum (and only) numerical value in row 2 of Table 1 ( MAX(Table 1 :: $2:2) ), then subtracts 1 to reach the fourth column of table 1.
Table 3 uses the same means to determine the row offset, but counts the number of dates entered into row 1 of Table 1 ( COUNT(Table 1 :: $1:1) ), then subtracts 1 to reach the same cell.
I prefer the method in Table 3 because it avoids the need for the second Header row and the possibility of overwriting the formulas in that row. (Row 2 of Table 1 may be deleted without affecting Table 3.) It does require that there be no empty cells in Row 1 from Column A to the column containing the latest date.
Regards,
Barry