Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default insert rows programmatically with formula change

I have a spread sheet that is grouped where the top line of the group
determines the Qty of Item and the Total value for the item

eg 1 Table (row 1) requires 1 table top, 2 chairs and 4 legs (rows 2 to 4)
if I change the qty in Row 1 (i.e. No of Tables) the parts automatically
change as well.

eg
Col A B C D
E
Qty Unit
formula Rate Value
Total
Row 1 1
300
Row 2 2 A2*A$1 50 100
Row 3 1 A3*A$1 100 100
Row 4 4 a4*A$1 25 100


I want to be able to copy this grouping so that the formula in column B (the
A$1 part) always refers to the relative Row 1 of the group i.e if I copy
and insert the group at Row 6 the formula in Row 6 would change to A7 * A$6
etc

Is there a way of using a command button to copy the group and then paste it
into the spreadsheet at the row that has been selected and then update the
formula in the rows with the row number of the insertion point

eg it copies the group , I then select row 13 as the insertion point, this
row number is stored in a variable, so that the formula in row 14, 15 and 16
is updated to A14*A$13, A15*A$13 and A16*A$13

I do have some knowledge of VBA but in Access not Excel so a dummies guide
would be much appreciated to any solution that may be offered

Thanks


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
insert rows in a worksheet that do not change adjoining rows craigandmel Excel Discussion (Misc queries) 2 April 29th 08 10:26 PM
Function to insert rows on a change in a cell Subhash Excel Discussion (Misc queries) 3 March 19th 08 04:35 AM
How to insert rows based on change in data Leoc Excel Worksheet Functions 2 January 23rd 08 10:12 PM
programmatically change pivot table rows/columns [email protected] Excel Programming 0 August 25th 05 05:33 AM
programmatically insert multiple blank rows in worksheet tag Excel Programming 3 July 31st 03 05:03 AM


All times are GMT +1. The time now is 04:41 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"