+ Reply to Thread
Results 1 to 5 of 5

Hide/Unhide Columns Depending on a specific cell value

  1. #1
    Registered User
    Join Date
    07-11-2009
    Location
    Essex, England
    MS-Off Ver
    Excel 2003
    Posts
    16

    Question Hide/Unhide Columns Depending on a specific cell value

    Hi All,

    I am looking or a code, (Or formula if one exists) to hide or un-hide columns depending on what is entered into a cell.

    I have attached an example to help clarify what i mean.

    Basically i want:

    If A2 is empty, hide columns C, D, E & F
    If A2 = Apple, Unhide columns C & D, but keep E & F hidden
    If A2 then becomes Banana, rehide C & D and unhide D&F

    Any help on this will be greatly appreciated
    Thanks in advance,
    Dave
    Attached Files Attached Files
    Last edited by DaveM13; 07-13-2009 at 05:48 PM.

  2. #2
    Forum Expert Paul's Avatar
    Join Date
    02-05-2007
    Location
    Wisconsin
    MS-Off Ver
    2016/365
    Posts
    6,887

    Re: Hide/Unhide Columns Depending on a specific cell value

    Hi Dave,

    Perhaps this will help you...
    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    07-11-2009
    Location
    Essex, England
    MS-Off Ver
    Excel 2003
    Posts
    16

    Re: Hide/Unhide Columns Depending on a specific cell value

    Paul,

    Perfect, exactly what i needed.

    Thank you very much,

    Dave

  4. #4
    Registered User
    Join Date
    07-19-2012
    Location
    Portland, Oregon
    MS-Off Ver
    Excel 2003
    Posts
    12

    Re: Hide/Unhide Columns Depending on a specific cell value

    Is there a way using these rules listed above, to hide columns in a different sheet. For instance if in sheet 1 I have a yes/no drop down and the person selects no, then can some columns on sheet 2 be hidden?

    Also, I have 3 sheets and I am trying to have separate code for all three sheets but when I put in the code for the 2nd sheet it screws up the code in the first sheet and the hidden columns aren't hidden anymore.

    Can you help? Thanks, Sheila

  5. #5
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Hide/Unhide Columns Depending on a specific cell value

    Hello sheilapowell, and welcome to the forum.

    Unfortunately you've inadvertently broken one of the forum rules. Please read the following. Thanks.

    Your post does not comply with Rule 2 of our Forum RULES. Don't post a question in the thread of another member -- start your own thread. If you feel it's particularly relevant, provide a link to the other thread. It makes sense to have a new thread for your question because a thread with numerous replies can be off putting & difficult to pick out relevant replies.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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