+ Reply to Thread
Results 1 to 4 of 4

Checkbox to hide rows using cell text as condition

  1. #1
    Registered User
    Join Date
    02-26-2016
    Location
    china
    MS-Off Ver
    2012
    Posts
    2

    Red face Checkbox to hide rows using cell text as condition

    Hi Everyone,

    I have a really simple question, but I tried searching all around and couldn't use the other topics to help me solve my problem.

    I just need a check box that when checked hides all the rows that have the word "OFF" on column A.

    Thanks a lot!

    -Dex

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Checkbox to hide rows using cell text as condition

    Hi, and welcome to the forum.

    That would require a macro. Are you sure you can't get what you want by filtering the data for values <> A ?

    A macro attached to a button or checkbox would do that for you but you may think Autofiltering is more straightforward.
    Then other option of course is to use a conditional format and set the font colour to the same colour as the cell background if OFF appear in a column A row,
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Registered User
    Join Date
    02-26-2016
    Location
    china
    MS-Off Ver
    2012
    Posts
    2

    Re: Checkbox to hide rows using cell text as condition

    Thanks for the reply, Richard.

    I already have conditional formatting on the rows, but I also need the option to hide them.

  4. #4
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Checkbox to hide rows using cell text as condition

    ...you didn't say whether you really needed a macro rather than just a plain old data filter.

    If so record a macro to hide the rows and link that to either a simple shape button, or the click event of a check box. When you have your macro then post it here and we'll be able to show you how to generalise it and make it more efficient - the macro recorder can't capture the most efficient way.

+ 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. Userform/checkbox hide/unhide rows based on cell value
    By MOHAMMESALMAN in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-03-2015, 03:17 AM
  2. [SOLVED] User form/checkbox hide/unhide rows based on cell value
    By ldonis in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-12-2014, 11:35 AM
  3. Replies: 2
    Last Post: 04-26-2014, 07:34 PM
  4. [SOLVED] Checkbox VBA - Hide/Unhide Rows and/or Columns based on cell values
    By gravy258 in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 02-21-2013, 05:39 PM
  5. Show/Hide columns by checkbox and cell text
    By ksmoore in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 11-09-2010, 02:20 PM
  6. Macro cannot hide rows based on cell linked to checkbox
    By fernaldd in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-04-2009, 11:46 AM
  7. Use Checkbox to hide rows
    By Tybalt in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-10-2008, 11: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