+ Reply to Thread
Results 1 to 3 of 3

Combine lists

  1. #1
    Registered User
    Join Date
    01-30-2010
    Location
    Delaware, USA
    MS-Off Ver
    Excel 2003
    Posts
    2

    Combine lists

    I have two separate lists in a workbook that are used to validate data for various fields. I have one field that needs to be a drop-down containing the combined data from both of these lists.

    I am trying to figure out how to do one of the following:

    1) Use validate to allow data that is contained in either of two lists without combining the lists into a single list (don't know if this is possible)

    2) Make a third list that contains the data from each of the initial two lists but which does not have to be maintained separately (i.e. if I add or remove data from list 1 or list 2, the appropriate change is made in list 3 as well).

    Any ideas?

  2. #2
    Forum Expert Palmetto's Avatar
    Join Date
    04-04-2007
    Location
    South Eastern, USA
    MS-Off Ver
    XP, 2007, 2010
    Posts
    3,978

    Re: Combine lists

    Any ideas?
    JBeaucaire, another guru on this forum, has developed an excellent approach that may work for you. See this link and see if it can be adapted per your needs.

    Auto Complete in a Data Validation cell technique
    Palmetto

    Do you know . . . ?

    You can leave feedback and add to the reputation of all who contributed a helpful response to your solution by clicking the star icon located at the left in one of their post in this thread.

  3. #3
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Combine lists

    If List 1 is in column A starting at row 2
    If List 2 is in column B starting at row 2
    To have List 3 create itself in column B starting at C2, put this formula in C2 and copy down as far as you'd like:

    =IF(ROW(A1)<=COUNTA($A$2:$A$100), INDEX($A$2:$A$100, ROW(A1)), IF(ROW(A1)<=COUNTA($A$2:$A$100)+COUNTA($B$2:$B$100), INDEX($B$2:$B$100, ROW(A1)-COUNTA($A$2:$A$100)), ""))

    Then use this formula to create a dynamic named range called MergedList from the changing values of column C:

    =OFFSET(Sheet2!$C$2,0,0,MATCH("*",Sheet2!$C:$C,-1)-1,1)

    Then use that named range in you drop down validation. Sample attached.
    Attached Files Attached Files
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

+ 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