+ Reply to Thread
Results 1 to 8 of 8

Find rows that contain specific text

  1. #1
    Forum Contributor
    Join Date
    07-30-2014
    Location
    Mosman, Australia
    MS-Off Ver
    2013
    Posts
    118

    Find rows that contain specific text

    Hi there

    I have a spreadsheet containing multiple data across rows. I only want items to appear based on certain text from one column, I want it to appear in chronological order however. This spreadsheet will be used by various people with data being entered daily, so the simple filter option won't work with what I want it to do.

    Basically, this is what it currently shows:

    Example A Subject A Open
    Example B Subject B Open
    Example C Subject C Closed
    Example D Subject D In Progress
    Example E Subject E Closed
    Example F Subject F Open

    Basically, I only want items that have either Open or In Progress status to appear, so using the above examples, the result should show:

    Example A Subject A Open
    Example B Subject B Open
    Example D Subject D In Progress
    Example F Subject F Open

    So it stays in alphabetical order, but anything where the status shows Closed does not appear.

    Is there a way to do this without the excel file going really slow, please let me know if I might need a macro to do this and I will post this in the VBA forum.

    Thanks

  2. #2
    Forum Expert NeedForExcel's Avatar
    Join Date
    03-16-2013
    Location
    Pune, India
    MS-Off Ver
    Excel 2016:2019, MS 365
    Posts
    3,874

    Re: Find rows that contain specific text

    Attach a sample workbook. Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic
    Cheers!
    Deep Dave

  3. #3
    Forum Expert
    Join Date
    09-01-2012
    Location
    Norway
    MS-Off Ver
    Office 365
    Posts
    2,844

    Re: Find rows that contain specific text

    Somthing like this?
    Attached Files Attached Files
    <----- If you were helped by my posts you can say "Thank you" by clicking the star symbol down to the left

    If the problem is solved, finish of the thread by clicking SOLVED under Thread Tools
    I don't wish to leave you with no answer, yet I sometimes miss posts. If you feel I forgot you, remind me with a PM or just bump the thread.

  4. #4
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,192

    Re: Find rows that contain specific text

    An alternative (no helper and non-array)

    =IFERROR(INDEX(A:A,SMALL(INDEX(($C$2:$C$7="Closed")*10^10+ROW($C$2:$C$7),0),ROWS($1:1))),"") drag across 3 columns for Header 1, 2 & 3 and down as far as needed. Adjust the ranges for C as needed.
    Attached Files Attached Files
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU

  5. #5
    Forum Expert
    Join Date
    03-20-2015
    Location
    Primarily UK, sometimes NL
    MS-Off Ver
    Work: Office 365 / Home: Office 2010
    Posts
    2,405

    Re: Find rows that contain specific text

    Hi,

    You can use the following macro to hide any Closed lines:

    Please Login or Register  to view this content.
    Replace Range("B1:B" with the column you need to search for 'Closed'.

    If you want to run this manually, just put it in a normal module.
    If you want it to run automatically when the file is opened, put it all in 'ThisWorkbook' preceded by this:
    Please Login or Register  to view this content.
    The attached file should show this working.
    HideRowIfTextFound.xls

    Please note, this is not all my work - the main macro is modified from code found here:
    http://answers.microsoft.com/en-us/o...0-28e74578f0c8

    Regards,
    Aardigspook

    If your problem is solved, please go to 'Thread Tools' on your first post and 'Mark Thread as Solved'.
    You don't need to give me rep if I helped, but thanks are appreciated.

  6. #6
    Forum Contributor
    Join Date
    07-30-2014
    Location
    Mosman, Australia
    MS-Off Ver
    2013
    Posts
    118

    Re: Find rows that contain specific text

    Thank you to everyone that assisted on this. Glenn, yours was spot on, the exact thing I wanted.

  7. #7
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,192

    Re: Find rows that contain specific text

    Glad to have helped! If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. It'd also be appreciated if you were to click the add Reputation button at the foot of any of the posts of those who helped you reach a solution.

  8. #8
    Forum Expert
    Join Date
    03-20-2015
    Location
    Primarily UK, sometimes NL
    MS-Off Ver
    Work: Office 365 / Home: Office 2010
    Posts
    2,405

    Re: Find rows that contain specific text

    Glad we could help. Even though my solution wasn't what you needed, it was useful for me to go through the VBA, so thanks to you too.

    Regards,
    Aardigspook

    If your problem is solved, please go to 'Thread Tools' on your first post and 'Mark Thread as Solved'.
    You don't need to give me rep if I helped, but thanks are appreciated.

+ 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. [SOLVED] VBA to Find Specific Text, then Copy range to next open cell under specific text
    By Remotruker in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-24-2015, 10:59 AM
  2. Search rows to find specific text and move to a different column ?
    By Udaipur99 in forum Excel - New Users/Basics
    Replies: 19
    Last Post: 03-19-2014, 01:11 PM
  3. [SOLVED] Find row cell containing specific text, then delete all rows ABOVE that cell
    By ks100 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 12-20-2013, 02:02 PM
  4. Replies: 2
    Last Post: 08-05-2013, 07:32 PM
  5. Find the row a specific text is in a data set & delete certain rows
    By bcn1988 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-29-2013, 03:52 PM
  6. [SOLVED] Macro to find specific text in a cell and then create multiple rows above
    By Willardio in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 09-21-2012, 09:52 AM
  7. Replies: 4
    Last Post: 09-18-2012, 10:54 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