Populating multiple worksheets with a master list?

bradnailer

New Member
Joined
Jul 27, 2007
Messages
26
I have a master data worksheet with employee names, employee #...

A3 - 1, A4 - last name, A5 - last name, A6 - employee #....
B4 - 2, B4 - last name....


I then created a master template worksheet and then copied it 50 times (one/employee) and ran a macro to name them 1,2,3....50. SO far so good - now I have a template for each employee but I need to fill in their data from the master worksheet.


What I want to do is automatically populate the worksheets with the data from the master worksheet that contains the first name, last name, employee #...so that I don't have to manually type (copy/paste) the data in again since its already in the master worksheet.


I was trying to find a way to automatically populate the first name, last name (& any other data I needed) to all 50 worksheets automatically.


The information I've searched for hasn't worked out for me yet?


Thanks!
 

Excel Facts

Shade all formula cells
To shade all formula cells: Home, Find & Select, Formulas to select all formulas. Then apply a light fill color.
I have a master data worksheet with employee names, employee #...

A3 - 1, A4 - last name, A5 - last name, A6 - employee #....
B4 - 2, B4 - last name....


I then created a master template worksheet and then copied it 50 times (one/employee) and ran a macro to name them 1,2,3....50. SO far so good - now I have a template for each employee but I need to fill in their data from the master worksheet.


What I want to do is automatically populate the worksheets with the data from the master worksheet that contains the first name, last name, employee #...so that I don't have to manually type (copy/paste) the data in again since its already in the master worksheet.


I was trying to find a way to automatically populate the first name, last name (& any other data I needed) to all 50 worksheets automatically.


The information I've searched for hasn't worked out for me yet?


Thanks!

I made incorrect cell references, they should be:

A3 - 1, B3 - first name, C3 - last name, D3 - employee #....
A4 - 2, B4 - first name, C4 - last name, D4 - employee #...
A5 - 3, B5 - ......
 
Upvote 0
Code:
Sub test()
Dim r As Range
With Sheets("master data")
    For Each r In .Range("a3", .Range("a" & Rows.Count).End(xlUp))
        Sheets.Add.Name = r.Value
        .Rows(r.Row).Copy Sheets(r.Value).Cells(1)
        Application.CutCopyMode = False
    Next
End With
End Sub
 
Upvote 0

Forum statistics

Threads
1,214,659
Messages
6,120,786
Members
448,992
Latest member
prabhuk279

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