Shauntethemt
New Member
- Joined
- Jul 10, 2024
- Messages
- 9
- Office Version
- 365
- Platform
- Windows
Hey y'all!
I am in charge of the payment system of 50 people and am using excel. All of the information is on a master spreadsheet and I want to autopopulate individual sheets that I can print out and give to each individual. For reference, on my Master sheet, A1 is my header "name" and B1:AU1 has all of the names of the individuals.
A2:A47 have all of the categories of things they are paying for. The cost of the items are in cells 2-47, but in columns B-AU. (I hope I worded that correctly)
I need a formula that not only creates individual sheets based on the names in B1:AU1, but i also need it to auto-populate the information for each individual. Currently, I have a code to create the individual sheets. But when I have to populate the information I have to go to each page and use the formula =Master!(letter)1 and then double click on the corner to make it populate everything in that respective column. There has to be an easier way.
here is the code that I have from a previous workbook that helped me understand how to copy the sheets but not how to populate the rest of the information
Option Explicit
Sub CopySheet()
Dim wsM As Worksheet
Dim wsNames As Range, c As Range
Set wsM = Sheets("Amirah")
Set wsNames = Sheets("Full Team").Range("A2:A" & Rows.Count).SpecialCells(2)
Application.ScreenUpdating = False
For Each c In wsNames
If Not Evaluate("ISREF('" & c.Value & "'!A2)") Then
wsM.Copy After:=Sheets(Sheets.Count)
ActiveSheet.Name = c.Value
End If
Next c
wsM.Select
Application.ScreenUpdating = True
End Sub
I am in charge of the payment system of 50 people and am using excel. All of the information is on a master spreadsheet and I want to autopopulate individual sheets that I can print out and give to each individual. For reference, on my Master sheet, A1 is my header "name" and B1:AU1 has all of the names of the individuals.
A2:A47 have all of the categories of things they are paying for. The cost of the items are in cells 2-47, but in columns B-AU. (I hope I worded that correctly)
I need a formula that not only creates individual sheets based on the names in B1:AU1, but i also need it to auto-populate the information for each individual. Currently, I have a code to create the individual sheets. But when I have to populate the information I have to go to each page and use the formula =Master!(letter)1 and then double click on the corner to make it populate everything in that respective column. There has to be an easier way.
here is the code that I have from a previous workbook that helped me understand how to copy the sheets but not how to populate the rest of the information
Option Explicit
Sub CopySheet()
Dim wsM As Worksheet
Dim wsNames As Range, c As Range
Set wsM = Sheets("Amirah")
Set wsNames = Sheets("Full Team").Range("A2:A" & Rows.Count).SpecialCells(2)
Application.ScreenUpdating = False
For Each c In wsNames
If Not Evaluate("ISREF('" & c.Value & "'!A2)") Then
wsM.Copy After:=Sheets(Sheets.Count)
ActiveSheet.Name = c.Value
End If
Next c
wsM.Select
Application.ScreenUpdating = True
End Sub