Results 1 to 6 of 6

VBA Match Cell Range to Worksheet Name and copy/paste to respective worksheet

Threaded View

rlsublime VBA Match Cell Range to... 11-20-2011, 02:48 AM
arlu1201 Re: VBA Match Cell Range to... 11-20-2011, 03:49 AM
foxguy Re: VBA Match Cell Range to... 11-20-2011, 04:12 AM
christoff12 Re: VBA Match Cell Range to... 10-24-2014, 04:06 PM
rlsublime Re: VBA Match Cell Range to... 11-20-2011, 06:51 PM
izet99 Re: VBA Match Cell Range to... 09-25-2014, 04:55 PM
  1. #1
    Forum Contributor
    Join Date
    11-20-2011
    Location
    Chicago, IL
    MS-Off Ver
    Excel 2007, Excel 2003, Excel 2010
    Posts
    284

    VBA Match Cell Range to Worksheet Name and copy/paste to respective worksheet

    Hello,

    I have a tab named "Data" and 2 other tabs named Bill and Jim. Column A in the Data tab contains Names of employees (Jim and Bill) and all employees have a corresponding tab. What I am trying to do is match the names in column A of the "data" tab with the corresponding sheets that have the same names and then paste the names into their respective sheets in column A. Everytime I populate I am trying to get it to paste in the next empty row. In the "data" tab there might be 5 entries for Jim and 3 for Bill and I am trying to get the 5 Jim entries to paste in the Jim tab and the 3 Bill entries to paste in the Bill tab. Any help on this would be greatly appreciated as I have been struggling with it for the past few hours.

    Thanks so much for your help in advance.
    The code below somewhat works but i cannot include the entire column.

    Public Sub sheettosheet()
    Dim wksht As Worksheet
    For Each wksht In Sheets
    If ActiveSheet.EntireColumn("A3").Value = wksht.Name Then
    ActiveSheet.Range("B3:U3").CurrentRegion.Copy Destination:=wksht.Range("A" & Rows.Count).End(xlUp).Offset(1)
    End If
    Next
    End Sub
    Last edited by rlsublime; 11-20-2011 at 07:00 PM. Reason: added details

Thread Information

Users Browsing this Thread

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

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