Create Marco to copy data and to paste in worksheets

Hiten Vakharia

Board Regular
Joined
Sep 25, 2013
Messages
66
Hi,
I would like to create a macro where data is picked from the row and is copied to 10 additional worksheet on the same spreadsheet.
If the worksheet is not the spread sheet then to create a new worksheet and paste the data.

eg. On sheet1 I have;
Row 1 - abc
Row 2 - def
Row 3 - ghi
Row 4 - jkl
Row 5 - mno
Row 6 - pqr
Row 7 - stu and so on....

I would like to copy ENTIRE row1 and to be pasted on sheet2, same as row2 on sheet3 and so on....

Please let me know if I am not clear

Thanks in advance

Regards,
Hiten
 
Hi,

Thanks for your quick reply.


How did you know 10 ? - It will not always be 10, it can be either 9 or 10 or 11 etc, so that is the reason to create worksheet according to the master sheet

Do I need to count how many cells in column A have data to determined how many sheets I need? - Yes

And So if there are already 14 sheets in the workbook and there are 40 rows in sheet one then I need to make 27 new sheets. Because your master sheet would not be included. - Yes

And for all the sheets already created the script would overwrite what ever data is already in row(1) - Yes

And how do I name all these new sheets? Just let the script give them default names. - No, Name has to be A2 of the worksheet created

And every time we run this script does it overwrite the data already in row (1) of those sheets already created. - Yes

See these are the details I need.

And next time you run the script if there are only 10 rows of data then we just overwrite the data in row 1 of sheets 2 to 11 is this correct? - Yes


Hope I am clear

Thanks,
Hiten
 
Upvote 0

Excel Facts

Control Word Wrap
Press Alt+Enter to move to a new row in a cell. Lets you control where the words wrap.
There are others on this forum that I think will be able to help you.
This is beyond my knowledgebase.
I will continue to monitor this thread to see what I can learn.
 
Upvote 0

Forum statistics

Threads
1,215,067
Messages
6,122,949
Members
449,095
Latest member
nmaske

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top