+ Reply to Thread
Results 1 to 2 of 2

Auto-populate data to a master worksheet

Hybrid View

  1. #1
    Registered User
    Join Date
    09-06-2013
    Location
    Birmingham, Alabama
    MS-Off Ver
    Excel 2010
    Posts
    1

    Auto-populate data to a master worksheet

    I am new and ask that you bear with me.. I have never posted to a thread but I have a problem that is over my head. I am attaching an example. I want my master list worksheet to automatically update when the data in the other worksheets (SE, ATNS, TC, VW, TMZ) is input. These "other" worksheets and the master list have the same columns/headings. Please help.
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    05-30-2012
    Location
    The Netherlands
    MS-Off Ver
    Office 365
    Posts
    14,987

    Re: Auto-populate data to a master worksheet

    Try this one on a dummy of your sheet.

    The name of the headers needs to be expanded.

    See the attached file.

    Please reply.


    Sub integratie_Oeldere_revisted_vs3()
    
    'I got a lot of help from AB33, to get this code working; thanks for that AB33.
    
    Dim wsTest As Worksheet
    
    'check if sheet "Consolidated" already exist
    
    Const strSheetName As String = "Consolidated"
     
    Set wsTest = Nothing
    On Error Resume Next
    Set wsTest = ActiveWorkbook.Worksheets(strSheetName)
    On Error GoTo 0
     
    If wsTest Is Nothing Then
        Worksheets.Add.Name = strSheetName
    End If
    
    With Sheets("Consolidated")
        .UsedRange.ClearContents
        .Range("A1:F1").Value = Array("sheet", "App ID", "Job #", "BU #", "Site Name", "etc")
        For Each Sh In Sheets
            With Sh
                If .Name <> "Consolidated" And .Name <> "MASTER LIST " Then
                     LR = .Cells(.Rows.Count, 1).End(xlUp).Row
                    If LR >= 2 Then
                       Rng = .Cells.Find("*", , , , xlByRows, xlPrevious).Row - 1
                       NR = Sheets("Consolidated").Cells.Find("*", , , , xlByRows, xlPrevious).Row + 1
                       If Rng > 0 Then
                        Sheets("Consolidated").Cells(NR, 1).Resize(Rng) = .Name
                        Sheets("Consolidated").Cells(NR, 2).Resize(Rng, 29) = .Range("A2").Resize(Rng, 29).Value
                      End If
                   End If
                End If
            End With
        Next
        On Error Resume Next
        .Range("F2:F" & .Rows.Count).SpecialCells(4).EntireRow.Delete
        .Columns("A:Z").EntireColumn.AutoFit
    End With
    End Sub
    Notice my main language is not English.

    I appreciate it, if you reply on my solution.

    If you are satisfied with the solution, please mark the question solved.

    You can add reputation by clicking on the star * add reputation.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Auto-populate data to a master worksheet from other sheets in a shared workbook
    By JennyJAL in forum Excel Programming / VBA / Macros
    Replies: 45
    Last Post: 08-20-2021, 12:08 AM
  2. Macro to Auto populate master worksheet
    By ctidwel in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-12-2012, 11:43 AM
  3. Replies: 3
    Last Post: 09-07-2012, 06:29 PM
  4. Auto Populate Master Sheet with multiple sheets data
    By haley in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-26-2009, 04:29 AM
  5. how to auto populate data from multiple sheets to a master
    By Fosachy in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-21-2009, 06:15 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1