SUB Rectangle 2_ Click () DIM I as INTEGERDIM YYY AS INTEGERFOR I = 1 to 20Sheets ("Sheet1"). Cells (i, 1) = inextyyyy = Application.WorksheetFunction.counta (Column ("A")) Cells YYY 1, 1) = Application.WorksheetFunction.Sum (Range (Cells (1, 1), Cells (YYY, 1))) End Subyyy is a non-empty number in the A column,