+ Reply to Thread
Results 1 to 5 of 5

need help displaying desired rows based on Yes and No question for multiple categories

  1. #1
    Registered User
    Join Date
    01-31-2014
    Location
    Michigan
    MS-Off Ver
    Excel 2016
    Posts
    13

    need help displaying desired rows based on Yes and No question for multiple categories

    I am working on a project that lists all the tasks to be completed within that project (100% display), but if some categories do not apply, I do not wish to see them in the list of tasks to be completed. I only want to see the tasks needed for that project (and the headers). On one tab, it would ask specific yes or no questions and on the other tab, I would like to see the Yes tasks listed. How can I do this?

    I have an example attached - just a fake one for a visual of what I am looking for...

    Please help!
    Thank you!!
    Debbie
    Attached Files Attached Files

  2. #2
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: need help displaying desired rows based on Yes and No question for multiple categories

    One solution: Requires VBA

    On "Tasks" I added a formula in Col D beginning with D3
    =IF(ISERROR(VLOOKUP(B3,Table1,2,FALSE)),"Yes", VLOOKUP(B3, Table1,2, FALSE))
    Then selecting the entire data range, applied an autofilter.
    Then I hid Column D

    Right click on Tasks Tab > "View Code
    and paste this code in there
    Please Login or Register  to view this content.
    Make changes on "Animals" and go back to "Tasks"
    Attached Files Attached Files
    Last edited by ChemistB; 11-06-2014 at 02:29 PM. Reason: Modified to make 2003 compatable
    ChemistB
    My 2?

    substitute commas with semi-colons if your region settings requires
    Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)
    If I helped, Don't forget to add to my reputation (click on the little star at bottom of this post)

    Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble

  3. #3
    Registered User
    Join Date
    01-31-2014
    Location
    Michigan
    MS-Off Ver
    Excel 2016
    Posts
    13

    Re: need help displaying desired rows based on Yes and No question for multiple categories

    I dont understand the "selecting the entire data range, applied an autofilter" step. And I don't see how the Task tab knows to look for "Yes" on the Animals tab?

  4. #4
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: need help displaying desired rows based on Yes and No question for multiple categories

    I dont understand the "selecting the entire data range, applied an autofilter" step.
    On the "Tasks" sheet, your data range (after adding the formulas in Column D is B2:D20. Select that range using the mouse so it's all highlighted
    Then, in Excel 2003> Menu "Data">Filter>Autofilter.
    You'll see the down arrows appear next to the headers in row 2.

    how the Task tab knows to look for "Yes" on the Animals tab?
    The formulas we wrote in D
    =IF(ISERROR(VLOOKUP(B3,Table1,2,FALSE)),"Yes", VLOOKUP(B3, Table1,2, FALSE))
    Table1 is a defined named range

    =Animals!$B$3:$C$6

    If you are more comfortable, just use the range and change the formula to

    =IF(ISERROR(VLOOKUP(B3,Animals!$B$3:$C$6, 2,FALSE)),"Yes", VLOOKUP(B3, Animals!$B$3:$C$6, 2, FALSE))

    The code that I asked you to paste in the "Tasks" worksheet code resets the autofillter to look for "yes'"

  5. #5
    Registered User
    Join Date
    01-31-2014
    Location
    Michigan
    MS-Off Ver
    Excel 2016
    Posts
    13

    Re: need help displaying desired rows based on Yes and No question for multiple categories

    Thank you!!! You are awesome!
    Debbie

+ 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. Displaying data from multiple rows in single row based on data values
    By Marnus in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 03-24-2014, 03:57 PM
  2. [SOLVED] Possible to Alternate Colors of Multiple Rows of Categories
    By syuzhet in forum Excel General
    Replies: 3
    Last Post: 11-01-2013, 10:07 AM
  3. Replies: 1
    Last Post: 04-06-2013, 06:21 AM
  4. [SOLVED] Can anyone please advise how to auto-rearrange rows of data, based on desired arrangement?
    By richardlimka in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-21-2012, 09:26 PM
  5. Delete Rows if value in cell does not equal desired value ACROSS multiple sheets
    By nature47 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-17-2009, 02:00 AM

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