Results 1 to 11 of 11

Cpying Unique entries to new spreadsheet

Threaded View

  1. #1
    Registered User
    Join Date
    02-24-2007
    Posts
    84

    Cpying Unique entries to new spreadsheet

    I'm trying to write a macro to use as an auto-update feature for a spreadsheet.

    I currently use Data validation on an input cell to allow the user to select from a list of product types.

    I'd like the update to affect this list, so new product types are always available to the user.

    However, the list of product types is in another spreadsheet and contains numerous repetitions.

    I've managed to get the following code together based on what I've used before and what I've found searching so far, but it seems to have a bug in it as it wont always work. I also need the original copying of the list to be done to either the new spreadsheet of a different page in the original spreadsheet, but every time I try this it causes an object error.

    PHP Code: 
    Sub Macro3()
    '
    Macro3 Macro
    ' Macro recorded 05/12/2008 by Information Technology
    '
        
    Workbooks.Open Filename:= _
            
    "T:\SST\CCD\Engineering\Backthin_data\Photolith\MASK_DETAILS.xls"
       
    Sheets("Mask List").Range("f4:f2000").AdvancedFilter Action:=xlFilterCopy_
            CriteriaRange
    :=Range("a1:a3"), CopyToRange:=Range("E1:E2000"), Unique:= _
            True
        Selection
    .Sort Key1:=Range("E1:e2000"), Order1:=xlAscendingHeader:=xlNo_
            OrderCustom
    :=1MatchCase:=FalseOrientation:=xlTopToBottom
            Columns
    ("E:E").Select
            Selection
    .Copy
          Windows
    ("MASK_DETAILS.xls").Activate
        ActiveWindow
    .Close
        Windows
    ("Dry_etcher_log_B.xls").Activate
        Sheets
    ("Calc Sheet").Select
        Columns
    ("M:M").Select
        ActiveSheet
    .Paste
     End Sub 
    Could someone kindly point me in the correct direction.

    Thank,
    Gavin.
    Last edited by gavster; 12-08-2008 at 07:47 AM.

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