Excel Macro - Add new range to existing Formula Office 2010 -


my macro inserts 8 lines of new job summary spreadsheet. these lines link different file name , has subtotal included =sum() formula (for each job). grand total not include new subtotal range in previous 4 job summary. there more jobs added later has keep working relative future jobs being potentially added. looking easy way add new range existing formula within grand totals cell. help.

right cell contains formula: =g37+g29+g21+g13 (these job summary subtotals) after adding 8 new rows of new job have add cell "g45" above formula within macro , if add job "g53". cell add 3 rows above formula want add formulas has continue work jobs updated daily or @ least weekly. help.

just append range sum function.

=sum(a1:a6) 

say want add in cells c1 through c6

=sum(a1:a6:c1:c6) 

say want add in cell d5

=sum(a1:a6:c1:c6,d5) 

say want add in cells e1 through e6

=sum(a1:a6:c1:c6,d5,e1:e6) 

Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -