+ Reply to Thread
Results 1 to 3 of 3

Automatic hiding of columns based on a cell value

  1. #1
    Registered User
    Join Date
    12-14-2016
    Location
    Paris, France
    MS-Off Ver
    2010
    Posts
    3

    Automatic hiding of columns based on a cell value

    Hello,

    I have this macro to hide columns based on the value of a cell but I would like to know how I could tweek it to make it hide 2 columns at a time ?

    Thank you very much for your help !

    Best regards,
    Hippolyte


    Please Login or Register  to view this content.
    Last edited by JBeaucaire; 12-14-2016 at 09:35 PM. Reason: Added missing CODE tags. Please read and follow the Forum Rules, link above in the menu bar. Thanks.

  2. #2
    Forum Expert
    Join Date
    12-15-2009
    Location
    Chicago, IL
    MS-Off Ver
    Microsoft Office 365
    Posts
    3,177

    Re: Automatic hiding of columns based on a cell value

    Use range instead. If you want to hide Column A and C, then change your .Columns to .Range("A:A, C:C").EntireColumn.Hidden = True

  3. #3
    Registered User
    Join Date
    12-14-2016
    Location
    Paris, France
    MS-Off Ver
    2010
    Posts
    3

    Re: Automatic hiding of columns based on a cell value

    Hello,

    What I would like to do is hide columns 13:52 if I input the value "1"; hide columns 15:52 if I input the value "2" and so on until value "20"

    Hope I'm being explicit enough.

    Thank you in advance for your help

+ 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. Hiding varied columns based on the value of one cell
    By drewfy in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-21-2015, 10:02 AM
  2. Hiding Columns based on Value in a Cell
    By packerfan in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-22-2015, 03:20 PM
  3. Hiding Multiple Columns based on Cell Value
    By simon_geoghegan in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 01-12-2015, 09:06 AM
  4. Hiding Columns based on Cell value
    By honger in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-28-2014, 02:44 PM
  5. [SOLVED] Hiding columns based on cell value (ListBox)
    By Big_Tater in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-16-2013, 10:38 PM
  6. Hiding Columns based on Cell Value
    By Dynamo418 in forum Excel General
    Replies: 1
    Last Post: 08-08-2012, 08:21 PM
  7. automatic hiding of columns
    By JediMaster in forum Excel General
    Replies: 0
    Last Post: 07-27-2010, 05:22 PM

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