Hi Telgus,
After reviewing your file in detail, I came to the conclusion that 'Data Tables' were probably not the correct approach for your application, because it probably would require too many changes to your Excel spreadsheet design. I apologize for leading you down the wrong path.
I came up with another solution that requires you to make ZERO changes to your file, subject to the following limitations:
a. Formula in Cell D1 is changed to: '=SUM(I1:I9999)' by both the VBA routines below.
b. Each Data Area requires at least 2 Data Rows to Maintain Totals Formulas.
See the attached modified copy of your file that contains the following two Macros in Ordinary Code Module ModManageDataArea:
a. RemoveAllBlankRowsFromCurrentDataArea()
b. AddBlankRowAtTheBottomOfCurrentDataArea()
The code in red below at the top of the Module can be modified to suit your needs if you change the Spreadsheet design.
Lewis
NOTE: Code Continued in next post due to size limitations
Bookmarks