How to Append Weekly Excel Data to a New Historical Row
Question details
The user wants to automatically save changing weekly cell values into a new row to keep a historical record.

- Product
- Spreadsheet
- Device & OS
- not provided
- Scenario
- Tracking weekly data where current input values overwrite previous ones, requiring a method to capture and store historical snapshots.
- Observed behavior
- Formulas update dynamically and cannot freeze or preserve past values once the source data changes.
Before implementing a macro, ensure your workbook is saved as a Macro-Enabled Workbook (.xlsm) and back up your data to prevent accidental overwriting during testing.
Redesign the Workbook Using a History Table and Dashboard
The most robust and maintainable approach is to separate data entry from data presentation without relying on macros.
Instead of overwriting the same cells each week and trying to push that data elsewhere, reverse the logic. Enter your data into a continuous table, and use a dashboard to display the current week's summary.
Create a dedicated 'History' sheet and set up an Excel Table (Insert > Table) with columns for Date, Metric 1, Metric 2, etc.
Enter your new weekly data directly into the next available row of this table instead of overwriting a single input cell.
Designate your original top section or a separate sheet as a 'Dashboard' for viewing the data.
Use lookup formulas (like VLOOKUP, INDEX/MATCH, or MAXIFS) in the Dashboard to automatically pull and display the most recent week's data from the History table.

Use a VBA Macro to Copy and Paste Values to a New Row
If you must keep your current layout where users overwrite a specific cell, use a VBA macro to copy the current values and append them to a historical list.
Easily Manage Macros and Data Tables with WPS Spreadsheet
WPS Spreadsheet provides full support for VBA macros and advanced table management, allowing you to automate historical data tracking effortlessly.
- 1. Open your Workbook: Launch WPS Spreadsheet and open your existing data tracking workbook.
- 2. Access Developer Tools: Go to the 'Developer' tab to access the VBA Editor and write your data-appending macro.
- 3. Create Structured Tables: Alternatively, use 'Insert' > 'Table' to structure your historical data for easy formula referencing without needing code.

Frequently Asked Questions
Why can't I use a formula to save historical data?
Formulas are dynamic and constantly recalculate based on their source cells. If the source cell changes, the formula output changes with it, making it impossible to 'freeze' a past value without using a macro or manual copy-pasting.
How do I find the next empty row using VBA?
You can find the next empty row in a specific column (e.g., Column A) using the VBA code: NextRow = Cells(Rows.Count, 1).End(xlUp).Row + 1. This looks from the bottom of the sheet upwards to find the last cell with data.
What is the difference between pasting and pasting values in VBA?
Standard pasting copies formulas, formatting, and values. Using PasteSpecial Paste:=xlPasteValues ensures that only the static text or numbers are pasted, which is essential for preserving historical snapshots that shouldn't change.
Can I automate the macro to run every week?
Yes, you can use the Application.OnTime method in VBA to schedule a macro, or use the Workbook_Open event combined with a date check to prompt the user to save the weekly snapshot automatically when the file is opened.




