Hi all,
I have a tab called ‘VBAinputs’. On this tab starting on cell A4 and descending are any number of text strings. Also on this tab cell C3 contains a number (this will be a starting copy row indicator) and cell D3 contains a number (this will be the number of rows in a copy block),
I have another tab called ‘SVPulls’ containing rows of data.
I would like some VBA to do the following with entire rows of data on the ‘SVPulls’ tab:
Starting at the row number designated in cell C3 of ‘VBAinputs’ (eg. 25) create a selection range that includes the whole row and a total number of rows designated in cell D3 of ‘VBAinputs’ (eg. 10). The range then will be copied as many times as there are text strings (starting in A4) in column A of ‘VBAinputs’. As each block is being copied the top left cell of the block needs to be the text string.
So let’s say in the ‘VBAinputs’ tab I have cells A4 to A7 as apples, pears, oranges, plums. Cell C3=25 and cell D3=10, the following will happen on the ‘SVpulls’ tab:
Starting at row 25 a block of 10 rows will be copied, this will be pasted repeating 4 times and in each paste block the top-right most cells will contain apples, pears, oranges, plums. No gaps required between paste blocks.
Thanks!
I have a tab called ‘VBAinputs’. On this tab starting on cell A4 and descending are any number of text strings. Also on this tab cell C3 contains a number (this will be a starting copy row indicator) and cell D3 contains a number (this will be the number of rows in a copy block),
I have another tab called ‘SVPulls’ containing rows of data.
I would like some VBA to do the following with entire rows of data on the ‘SVPulls’ tab:
Starting at the row number designated in cell C3 of ‘VBAinputs’ (eg. 25) create a selection range that includes the whole row and a total number of rows designated in cell D3 of ‘VBAinputs’ (eg. 10). The range then will be copied as many times as there are text strings (starting in A4) in column A of ‘VBAinputs’. As each block is being copied the top left cell of the block needs to be the text string.
So let’s say in the ‘VBAinputs’ tab I have cells A4 to A7 as apples, pears, oranges, plums. Cell C3=25 and cell D3=10, the following will happen on the ‘SVpulls’ tab:
Starting at row 25 a block of 10 rows will be copied, this will be pasted repeating 4 times and in each paste block the top-right most cells will contain apples, pears, oranges, plums. No gaps required between paste blocks.
Thanks!