+ Reply to Thread
Results 1 to 9 of 9

Filter Listview based multiple combobox

Hybrid View

  1. #1
    Valued Forum Contributor
    Join Date
    01-11-2012
    Location
    Riyadh, K.S.A.
    MS-Off Ver
    Windows 11 with Excel 2013 & 2016
    Posts
    905

    Filter Listview based multiple combobox

    Hello Again,

    I am looking for a help on filtering fields on Listview control.

    Let say I am searching Emergency main category as Description (English) in column F and I select dental in combobox5 then it will display only those records which is having Emergency in column F and Dental in column I

    Another example. Let say I searching Filling in column F (Description (English) and select dental in combobox5 the it will display only those records which is having filling in column f and Dental in column I.

    I hope I have explained my request correctly.

    Copy of a sample worksheet is attached for your reference.
    Attached Files Attached Files

  2. #2
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Filter Listview based multiple combobox

    Hi hecgroups

    Far as I can tell, it's a bit uncertain, as Sample Data does not jive:
    • Combobox2 relates to Column B
    • Combobox3 relates to Column C
    • Combobox4 relates to Column D
    • Combobox5 relates to Column I
    • Combobox6 relates to Sheet Names.
    Is this correct?
    Last edited by jaslake; 01-27-2015 at 08:37 PM.
    John

    If you have issues with Code I've provided, I appreciate your feedback.

    In the event Code provided resolves your issue, please mark your Thread as SOLVED.

    If you're satisfied by any members response to your issue please use the star icon at the lower left of their post.

  3. #3
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Filter Listview based multiple combobox

    Yes? No? Maybe?

    Quote Originally Posted by jaslake View Post
    Hi hecgroups

    Far as I can tell, it's a bit uncertain, as Sample Data does not jive:
    • Combobox2 relates to Column B
    • Combobox3 relates to Column C
    • Combobox4 relates to Column D
    • Combobox5 relates to Column I
    • Combobox6 relates to Sheet Names.
    Is this correct?

  4. #4
    Valued Forum Contributor
    Join Date
    01-11-2012
    Location
    Riyadh, K.S.A.
    MS-Off Ver
    Windows 11 with Excel 2013 & 2016
    Posts
    905

    Re: Filter Listview based multiple combobox

    Sorry for the delay. yes you are correct.

    1 more thing I want to mention.

    Let say I enter a criteria and select main category and hit search button. Later on I want to filter the search by Combobox 5. When I select Dental from Comboox5 automatically I will filter the data no need to hit the search button again.

    Other case is I enter a criteria and select main category with other filter option whatever maybe class, Type or region and hit search button it will filter and give me the output.

    what I am trying to tell you is the filter option should work before or after search.

  5. #5
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Filter Listview based multiple combobox

    Hi hecgroups

    Try the Code in the attached...I THINK it accomplishes this...you'll need to tell me...
    the filter option should work before or after search
    Attached Files Attached Files

  6. #6
    Valued Forum Contributor
    Join Date
    01-11-2012
    Location
    Riyadh, K.S.A.
    MS-Off Ver
    Windows 11 with Excel 2013 & 2016
    Posts
    905

    Re: Filter Listview based multiple combobox

    Thanks for your effort to help me out. Please give me some time to take a look and get back to you.

  7. #7
    Valued Forum Contributor
    Join Date
    01-11-2012
    Location
    Riyadh, K.S.A.
    MS-Off Ver
    Windows 11 with Excel 2013 & 2016
    Posts
    905

    Re: Filter Listview based multiple combobox

    Thanks jaslake. the file working good but only few things I want to mentioned.

    Let say I want to extend my search it is taking lot of time to check again in entire database. let say I search for Emergency in entire pricelist database. After taking 20 to 25 mins it is displaying the result on listview. Then I again I am looking same service in specific class (Ex. Class C+), then again it is searching entire database and taking the same time 25-30 mins.

    what I want here is first search will look into database in second search it should look into viewlist records.

    For example I am searching Emergency in entire database and found records 500. Then again without changing existing search I am selecting Class C+ then it should look into that 500 records only instead of entire database.

    I hope I have explained my issue correctly.

    Waiting for your response. if cannot be cone I will mark this thread as solved.

    Again thank you very much for your effort to help me out.

  8. #8
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Filter Listview based multiple combobox

    Hi hecgroups

    I believe I had forewarned you of this...

    http://www.excelforum.com/excel-prog...-workbook.html

    See Post #7
    5 million records???...the Code may take DAYS to run...
    Far as I know, one cannot Filter a List View Control...one can delete records from the List View Control but that's beyond the scope of this Thread.

    I'd suggest you get Professional Help in Commercial Services.

  9. #9
    Valued Forum Contributor
    Join Date
    01-11-2012
    Location
    Riyadh, K.S.A.
    MS-Off Ver
    Windows 11 with Excel 2013 & 2016
    Posts
    905

    Re: Filter Listview based multiple combobox

    OK Thanks for your help. Topic marked as solved and reputation is added.

+ 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. combobox to filter based on two previous comboboxes
    By zak.horrocks in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-02-2014, 11:34 AM
  2. [SOLVED] Excel: Display combobox as listview subitem
    By ChrisVBA in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 10-07-2014, 10:03 AM
  3. [SOLVED] Help ListView Filter
    By Kimaos in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-20-2014, 04:41 AM
  4. [SOLVED] combobox filter based on textbox value
    By mabulco in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-13-2013, 06:24 AM
  5. Filter Listview based on TextBox Value
    By ioncila in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-17-2012, 02:33 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