Results 1 to 5 of 5

Hide rows based on cell values

Threaded View

  1. #1
    Registered User
    Join Date
    06-18-2009
    Location
    Michigan
    MS-Off Ver
    Excel 2003
    Posts
    2

    Hide rows based on cell values

    Hello,
    VBA novice here, and hopefully someone can help!
    Writing a tax compilation sheet for preparers - users have to fill in Cells A10, B10, and C10 with either "yes" or "no" from a drop-down data validation list.

    If users select "yes" for all 3 cells ---> rows 150 - 200 will be displayed. If any of the cells are "no", then I want the rows 150 - 200 to be hidden.
    I've been successful with the following code for one y/n question, but it won't work for the 3 criteria test:

    If ActiveCell.Offset(columnOffset:=1) = "cond1" Then
        If ActiveCell = "Yes" Then
            Rows("27:38").Hidden = False
           Else
             Rows("27:38").Hidden = True  
        End If
    End If
    Any insight is appreciated, and thanks in advance
    Last edited by DonkeyOte; 06-18-2009 at 05:00 PM. Reason: code tags added (on behalf of OP in lieu of latter post)

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

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