+ Reply to Thread
Results 1 to 2 of 2

Two ComboBoxes that filters out an item in one ComboBox if selected in the other Combobox

  1. #1
    Registered User
    Join Date
    01-14-2020
    Location
    Singapore
    MS-Off Ver
    365
    Posts
    2

    Two ComboBoxes that filters out an item in one ComboBox if selected in the other Combobox

    Hi. I would like to create 2 ComboBoxes (ActiveX Control). Both will have the same list. If an item is selected in ComboBox1, I would like that item to be filtered out or removed from the selection in ComboBox 2 and vice versa.

    I want to have the following list in ComboBoxes:

    Report 1
    Report 2
    Report 3
    Report 4

    I already tried using Dynamic data validation but it will still let you select same 2 items in 2 drop down list.

    Hope someone could help me. I tried every solution I found on net but non of them worked.

  2. #2
    Registered User
    Join Date
    01-14-2020
    Location
    Cary, North Carolina
    MS-Off Ver
    Excel 2013
    Posts
    1

    Re: Two ComboBoxes that filters out an item in one ComboBox if selected in the other Combo

    create a function that adds the items to the combobox based on the combo box before it. send the previous combo box and the new combobox to the function. create a do loop that loops to the end of the list of the first combo box and use the add function to copy the list of the first combo box to the new combo box with the condition that the text in first combo box does not equal the list value of the first combo box that the loop is currently on. the only issue with this you can only add one at a time. my solution is to grey out the first combo box when they make a selection. I then have a go back button to undo the selection and modify the first combo box. not sure if this is the solution you are looking for but I hope it helps.

+ 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. Need support to write code for multiple combobox filters for final combobox
    By dheeraj1990 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-30-2019, 08:42 AM
  2. selecting an item in combobox, the item does not get selected
    By AVM in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-14-2014, 05:14 AM
  3. Replies: 3
    Last Post: 04-02-2013, 06:02 PM
  4. Combobox: How to determine the location of the selected item if combobox has rowsource
    By ahsanzafar in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-11-2012, 03:24 PM
  5. Value of selected item in Combobox
    By Boris88 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-22-2011, 09:56 AM
  6. How to create an already-selected item within a combobox
    By guarroman in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-22-2010, 12:38 PM
  7. ComboBox selected item
    By ballabali in forum Excel General
    Replies: 1
    Last Post: 12-15-2005, 11:55 AM

Tags for this Thread

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