Error Checking in Excel
Thanks Thanks:  0
Likes Likes:  0
Results 1 to 3 of 3

Thread: tricky one eh??

  1. #1
    New Member
    Join Date
    May 2002
    Posts
    4
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    how do I conditionally hide a row? for example if b5="Jack" then the entire row should be hidden. Pls help.. Thanks in advance

  2. #2
    MrExcel MVP Jay Petrulis's Avatar
    Join Date
    Mar 2002
    Location
    Chicago, IL USA
    Posts
    2,040
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    On 2002-05-03 11:04, pra wrote:
    how do I conditionally hide a row? for example if b5="Jack" then the entire row should be hidden. Pls help.. Thanks in advance
    In a sheet module, use wither a worksheet_change or a worksheet_selectionchange event

    Private Sub Worksheet_SelectionChange(ByVal Target As Excel.Range)
    If Range("B5") = "Jack" Then
    Rows(5).Hidden = True
    Else
    Rows(5).Hidden = False
    End If
    End Sub

    EDIT:

    Please don't start a new thread with the same question.

    Also, please allow some time before you post and then repost. 7 whole minutes elapsed before your first request until the second one. Be reasonable. Not everybody can be your personal Excel consultant. A little patience for you!

    [ This Message was edited by: Jay Petrulis on 2002-05-03 11:43 ]

  3. #3
    MrExcel MVP Ivan F Moala's Avatar
    Join Date
    Feb 2002
    Location
    Auckland, New Zealand
    Posts
    4,209
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Jay is right....please don't restart
    another thread...otherwise people will
    waste there time.....I just queried another
    one of your Q above and now find that Jay
    has answered you. :-0
    Kind Regards,
    Ivan F Moala From the City of Sails

Some videos you may like

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •