I have a spreadsheet for recording various financial data, at the bottom of which are subtotals [subtotal(9,range)] of some but not all columns.
I've got the following Code to insert new rows, copying formulas from a hidden row at the top of the spreadsheet.
A = Int(InputBox("No of New rows?", "DATA ENTRY"))
LastRow = Range("A" & Rows.Count).End(xlUp).Row
Rows(LastRow).Resize(A).Insert Shift:=xlDown
Rows(1).Copy Range("A" & LastRow).Resize(A)
Rows(LastRow).Resize(A).Hidden = False
This successfully inserts new rows with formulas.
The problem I have is that my subtotals don't update to include my newly inserted row(s)
Does anyone have any ideas how to overcome this?
Help gratefully received.
I've got the following Code to insert new rows, copying formulas from a hidden row at the top of the spreadsheet.
A = Int(InputBox("No of New rows?", "DATA ENTRY"))
LastRow = Range("A" & Rows.Count).End(xlUp).Row
Rows(LastRow).Resize(A).Insert Shift:=xlDown
Rows(1).Copy Range("A" & LastRow).Resize(A)
Rows(LastRow).Resize(A).Hidden = False
This successfully inserts new rows with formulas.
The problem I have is that my subtotals don't update to include my newly inserted row(s)
Does anyone have any ideas how to overcome this?
Help gratefully received.