+ Reply to Thread
Results 1 to 3 of 3

Filter columns based of drop down/multi selection

  1. #1
    Registered User
    Join Date
    02-12-2019
    Location
    Texas
    MS-Off Ver
    2013
    Posts
    2

    Filter columns based of drop down/multi selection

    I am having trouble finding a forum that answers my questions. I am looking to hide columns based off a selection from a drop down combo box assigned to cell D1. I tried using helper rows that show what columns have that title selected in the drop down, but am unsure how to assign a code to hide columns that do not contain that text.

    For example:

    There are a list of columns with the titles Cust 1, Cust 1, Cust 2, Cust 3, Cust 4, Cust 4, Cust 3. Some of these columns have the same name, but not necessarily next to one another. I have recorded macros to hide the columns based on the selection, but I would be unable to add any columns in between.

    There is also the issue of needing to select more than one option at times.

    Essentially I need a code to hide the columns that do not contain a certain text in its header.
    Attached Files Attached Files
    Last edited by cessary; 02-12-2019 at 11:35 AM.

  2. #2
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,474

    Re: Filter columns based of drop down/multi selection

    Attaching a sample workbook enables others to work on your problem:

    To attach a sample workbook. Make sure there is just enough data to make it clear what is needed. Include BEFORE/AFTER sheets if needed to show the process you're trying to complete or automate. Remember to desensitize the data.

    Click on GO ADVANCED and click "manage attachments" to open the upload window.

    -




    See clip
    To add a file to a post

  3. #3
    Registered User
    Join Date
    02-12-2019
    Location
    Texas
    MS-Off Ver
    2013
    Posts
    2

    Re: Filter columns based of drop down/multi selection

    Update - Solved my own, but thought I'd attach my solution in case someone else has this type of question. If anyone finds a better solution, please let me know.
    Attached Files Attached Files

+ 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. Change the drop down values, based on selection in other columns(drop downs)
    By zeebee in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-18-2017, 01:16 PM
  2. Replies: 1
    Last Post: 07-04-2017, 09:00 PM
  3. [SOLVED] VBA to Amend the Filter Selection on a Pivot Table Based on a Drop Down List
    By The_Snook in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 03-22-2017, 10:00 AM
  4. Filter based macros to be further filtered by drop down selection?
    By JRC1 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-21-2017, 05:42 AM
  5. [SOLVED] Filter/Hide rows in a table based on drop-down selection?
    By kestefon in forum Excel General
    Replies: 4
    Last Post: 01-21-2015, 11:12 AM
  6. Replies: 3
    Last Post: 06-26-2013, 07:51 PM
  7. Changing Pivot Report Filter based on Drop Down List Selection
    By rajuasq in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-03-2012, 11:40 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