• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 279
  • Last Modified:

How do I enter data on a worksheet and have it populate on other worksheets within the workbook

I would like Last Name and First name to carry from worksheet 1 to worksheet 2 in a workbook.  Is there a macro solution or any other solution?
0
jstanisl
Asked:
jstanisl
  • 3
  • 3
1 Solution
 
sungenwangCommented:
On worksheet 2 put (='worksheet1'!A1) if the names are in cell A1
0
 
sungenwangCommented:
Actually it should be:
=Sheet1!$A$1
0
 
jstanislAuthor Commented:
This is helpful but here is what I am trying to do.  I have a workbook that users are filling out and there is different info on each tab but for example ID # firstname, lastname repeats across worksheets.  I want them to be able to fill out the information on the first sheet and then when they go to the other sheets the basic demographics are pre-populated based on what they entered on the first sheet.  This will work but I would have to put the formula with a row number in every row/column.  Is there a way to do this without specifying the row and column?
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
SiddharthRoutCommented:
Yes using a macro. :)

If you can upload a sample file then maybe I can help you?

Sid
0
 
jstanislAuthor Commented:
Attached is a sample of the file.  I would like to enter the last name and first name for example on the demographics sheet and have it carry over to the sheets named assignments and related services.
Copy-of-Case-Manager-Assignments.xls
0
 
sungenwangCommented:
Here's a quick macro to copy ID, LName, FName over.
sew

Sub CopyNames()
    For intSrcRow = 3 To Worksheets("Demographics").Cells(Cells.Rows.Count, "A").End(xlUp).Row
        strID = Worksheets("Demographics").Cells(intSrcRow, "A").Value
        Worksheets("Assignments").Cells(intSrcRow, "A").Value = strID
        Worksheets("Related Services").Cells(intSrcRow, "A").Value = strID
    Next

    For intSrcRow = 3 To Worksheets("Demographics").Cells(Cells.Rows.Count, "B").End(xlUp).Row
        strID = Worksheets("Demographics").Cells(intSrcRow, "B").Value
        Worksheets("Assignments").Cells(intSrcRow, "B").Value = strID
        Worksheets("Related Services").Cells(intSrcRow, "B").Value = strID
    Next

    For intSrcRow = 3 To Worksheets("Demographics").Cells(Cells.Rows.Count, "C").End(xlUp).Row
        strID = Worksheets("Demographics").Cells(intSrcRow, "C").Value
        Worksheets("Assignments").Cells(intSrcRow, "C").Value = strID
        Worksheets("Related Services").Cells(intSrcRow, "C").Value = strID
    Next
End Sub

Sub CopyNames()
    For intSrcRow = 3 To Worksheets("Demographics").Cells(Cells.Rows.Count, "A").End(xlUp).Row
        strID = Worksheets("Demographics").Cells(intSrcRow, "A").Value
        Worksheets("Assignments").Cells(intSrcRow, "A").Value = strID
        Worksheets("Related Services").Cells(intSrcRow, "A").Value = strID
    Next

    For intSrcRow = 3 To Worksheets("Demographics").Cells(Cells.Rows.Count, "B").End(xlUp).Row
        strID = Worksheets("Demographics").Cells(intSrcRow, "B").Value
        Worksheets("Assignments").Cells(intSrcRow, "B").Value = strID
        Worksheets("Related Services").Cells(intSrcRow, "B").Value = strID
    Next

    For intSrcRow = 3 To Worksheets("Demographics").Cells(Cells.Rows.Count, "C").End(xlUp).Row
        strID = Worksheets("Demographics").Cells(intSrcRow, "C").Value
        Worksheets("Assignments").Cells(intSrcRow, "C").Value = strID
        Worksheets("Related Services").Cells(intSrcRow, "C").Value = strID
    Next
End Sub

Open in new window

Copy-of-Case-Manager-Assignments.xls
0
 
jstanislAuthor Commented:
Thanks!
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 3
  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now