littlefish71
New Member
- Joined
- Mar 27, 2013
- Messages
- 4
Hi Guys,
I have had some luck but my method had led me in a direction which is making things tricky. So I need some help!!
I have a table which appears below. Column C indicates the serial number of an item which has been checked. Column D indicates the last serial number which is checked in the range.
ie: item 'a' serial numbers 285 to 295 have been checked. What I require is row 2 to be copied and inserted on the next row and automatically index the serial number to 286 until it reaches the last serial number of 295.
ie: the macro inserts 11 rows of all the same data except for column C which indexes on each row. Then moves onto the next row ie: in this table it is row 3 is copied and repeated 4 times indexing 352 to 355 and so on. if there is only 1 serial number then it remains as is.
<TBODY>
</TBODY>
Part Finished table
<TBODY>
</TBODY>
I have had some luck but my method had led me in a direction which is making things tricky. So I need some help!!
I have a table which appears below. Column C indicates the serial number of an item which has been checked. Column D indicates the last serial number which is checked in the range.
ie: item 'a' serial numbers 285 to 295 have been checked. What I require is row 2 to be copied and inserted on the next row and automatically index the serial number to 286 until it reaches the last serial number of 295.
ie: the macro inserts 11 rows of all the same data except for column C which indexes on each row. Then moves onto the next row ie: in this table it is row 3 is copied and repeated 4 times indexing 352 to 355 and so on. if there is only 1 serial number then it remains as is.
A</SPAN> | B</SPAN> | C</SPAN> | D</SPAN> | |||
1</SPAN> | Prod date</SPAN> | Item Name</SPAN> | 1st Item No.</SPAN> | Last Item No.</SPAN> | </SPAN> | |
2</SPAN> | 01/01/2013</SPAN> | a</SPAN> | 285</SPAN> | 288</SPAN> | </SPAN> | |
3</SPAN> | 01/01/2013</SPAN> | b</SPAN> | 352</SPAN> | 356</SPAN> | </SPAN> | |
4</SPAN> | 01/01/2013</SPAN> | c</SPAN> | 343</SPAN> | </SPAN> | ||
5</SPAN> | 01/01/2013</SPAN> | d</SPAN> | 108</SPAN> | </SPAN> | ||
6</SPAN> | 01/01/2013</SPAN> | e</SPAN> | 200</SPAN> | 208</SPAN> | </SPAN> | |
7</SPAN> | 01/01/2013</SPAN> | f</SPAN> | 30</SPAN> | </SPAN> | ||
8</SPAN> | 01/01/2013</SPAN> | g</SPAN> | 62</SPAN> | 63</SPAN> | </SPAN> | |
<TBODY>
</TBODY>
Part Finished table
1</SPAN> | Prod date</SPAN> | Item Name</SPAN> | 1st Item No.</SPAN> | Last Item No.</SPAN> |
2</SPAN> | 01/01/2013</SPAN> | a</SPAN> | 285</SPAN> | 288</SPAN> |
3</SPAN> | 01/01/2013</SPAN> | a</SPAN> | 286</SPAN> | 288</SPAN> |
4</SPAN> | 01/01/2013</SPAN> | a</SPAN> | 287</SPAN> | 288</SPAN> |
5</SPAN> | 01/01/2013</SPAN> | a</SPAN> | 288</SPAN> | 288</SPAN> |
6</SPAN> | 01/01/2013</SPAN> | b</SPAN> | 352</SPAN> | 356...</SPAN> |
<TBODY>
</TBODY>