+ Reply to Thread
Results 1 to 2 of 2

Macro to create multiple tables from one table.

  1. #1
    Registered User
    Join Date
    02-25-2011
    Location
    Phoenix, AZ
    MS-Off Ver
    Excel 2007
    Posts
    1

    Macro to create multiple tables from one table.

    Hello,

    I'm trying to create multiple worksheets with filtered information an original source table. I run the macro and it is not pasting the filter information in the new worksheets. Here is code, can somebody help me on why the info is not being pasted?

    ActiveWindow.SmallScroll Down:=-3
    ActiveCell.Cells.Select
    Selection.AutoFilter
    ActiveSheet.Range("$A$1:$N$18604").AutoFilter Field:=1, Criteria1:="8523"
    ActiveWindow.SmallScroll Down:=-3
    ActiveCell.Range("A1:N18001").Select
    Selection.Copy
    Sheets.Add After:=Sheets(Sheets.Count)
    ActiveSheet.Paste
    Sheets("Sheet2").Select
    Sheets("Sheet2").Name = "8523"

  2. #2
    Valued Forum Contributor Charles's Avatar
    Join Date
    02-10-2004
    Location
    Biloxi
    MS-Off Ver
    Windows 7, Excel 2003,2007 & Mac2011
    Posts
    845

    Re: Macro to create multiple tables from one table.

    VivatJesus,

    Welcome to the forum.
    Copy this code to a module and test.
    If you look at the code I made the assumption the the data is in sheet1.
    You can change it to your sheet name. Also from your request I show the New sheet will be named as the filter critical1. That is "8523".


    Please Login or Register  to view this content.
    Charles

    There are other ways to do this, this is but 1 !
    Be Sure you thank those who helped.
    IF YOU'RE SATISFIED BY ANY MEMBERS RESPONSE TO YOUR ISSUE PLEASE USE THE STAR ICON AT THE BOTTOM LEFT OF THE POST UNDER THEIR NAME.

+ Reply to Thread

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