+ Reply to Thread
Results 1 to 5 of 5

New line for each unique combination of values from different sheets

  1. #1
    Registered User
    Join Date
    08-08-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2003
    Posts
    2

    New line for each unique combination of values from different sheets

    Hi,

    I've been unable to find that answer to this, but this could be partly because I don't really know what it would be called.

    I have 2 columns of data and I want to pair them.

    Sheet 1 has a long list of part numbers/product codes. Sheet 2 has 3 customer types.

    I would like to publish into Sheet 3 every unique combination of these two value. Eg:

    Product 1 Customer 1
    Product 1 Customer 2
    Product 1 Customer 3
    Product 2 Customer 1
    Product 2 Customer 2
    etc etc

  2. #2
    Forum Expert daffodil11's Avatar
    Join Date
    07-11-2013
    Location
    Phoenixville, PA
    MS-Off Ver
    MS Office 2016
    Posts
    4,465

    Re: New line for each unique combination of values from different sheets

    Something like this could do it. Adjust the ranges on Sheet1 and Sheet2 as needed.

    Please Login or Register  to view this content.
    Make Mom proud: Add to my reputation if I helped out!

    Make the Moderators happy: Mark the Thread as Solved if your question was answered!

  3. #3
    Registered User
    Join Date
    08-08-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2003
    Posts
    2

    Re: New line for each unique combination of values from different sheets

    Excuse me for asking. How do I use this piece of code?

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: New line for each unique combination of values from different sheets

    There's a workbook at https://app.box.com/s/47b28f19d794b25511be that will do this.
    Entia non sunt multiplicanda sine necessitate

  5. #5
    Forum Expert daffodil11's Avatar
    Join Date
    07-11-2013
    Location
    Phoenixville, PA
    MS-Off Ver
    MS Office 2016
    Posts
    4,465

    Re: New line for each unique combination of values from different sheets

    You can use VB Code by entering it into the VB Editor.

    In Excel hit Alt+F11, Insert -> Module, Paste the code there, close that window.

    You can call the macro with Alt+F8 and choosing it from the menu that appears.

+ 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. Finding a unique combination of values
    By bassiere in forum Excel Programming / VBA / Macros
    Replies: 17
    Last Post: 08-27-2013, 10:20 AM
  2. Macro for the fetching values on basic of unique combination of more than one column value
    By manish_nichante in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 06-06-2013, 09:35 PM
  3. [SOLVED] identify unique ID between 2 sheets, auto replace cell values between sheets in diff colum
    By DT123456 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 07-25-2012, 08:25 AM
  4. [SOLVED] How do I move a line marker on a line column combination chart?
    By dknj30 in forum Excel General
    Replies: 7
    Last Post: 05-08-2012, 09:21 AM
  5. Replies: 0
    Last Post: 12-22-2011, 03:42 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