+ Reply to Thread
Results 1 to 4 of 4

Hide columns based on specific cell value

  1. #1
    Registered User
    Join Date
    05-29-2010
    Location
    England
    MS-Off Ver
    Excel 2003
    Posts
    58

    Hide columns based on specific cell value

    Hi I've searched the forum but can't find a specific way of doing this. I'm a beginner when it comes to VBA so would appreciate the help here.

    I have formula in cells C58:CJ58 - the result will either be zero or a number. I would like a code that, everytime that sheet is opened, will hide any column where the cell on row 58 is zero. Ideally I don't want this to affect other columns in the sheet, but if it does, I can sort that out.

    Is this possible?

    Thanks in advance!

  2. #2
    Forum Expert
    Join Date
    04-22-2013
    Location
    .
    MS-Off Ver
    .
    Posts
    4,418

    Re: Hide columns based on specific cell value

    Try this - it needs to go in the worksheet object in the visual basic editor.

    Please Login or Register  to view this content.

  3. #3
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: Hide columns based on specific cell value

    hi samcdavies, different option
    Please Login or Register  to view this content.
    Last edited by watersev; 05-14-2013 at 05:58 AM.

  4. #4
    Registered User
    Join Date
    05-29-2010
    Location
    England
    MS-Off Ver
    Excel 2003
    Posts
    58

    Re: Hide columns based on specific cell value

    Thankyou both. I used the first one simply becaue it was first, but they both work.

    Thanks again,
    Sam

+ Reply to Thread

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