LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Pennington
 
Posts: n/a
Default Hiding cells on condition

I am trying to hide a range of cells when the value in another cell is FALSE
and show the range of cells when the value is TRUE. My code is as follows but
it doesn't work
Private Sub Workbook_Open()
If Range("C4").Value = False Then
Range("E4:M40").Hide = True
End If
If Range("C4").Value = True Then
Range("E4:M40").Unhide = False
End Sub

How do I make this work?
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
sum of a cell if 2 cells meet a condition Markitos Excel Worksheet Functions 4 January 4th 05 05:27 PM
Heps to design Locked/Unlocked cells in protected worksheet Kevin Excel Discussion (Misc queries) 0 December 30th 04 07:09 AM
Hiding Formula in cells thrava Excel Discussion (Misc queries) 2 December 23rd 04 12:42 AM
How to add cells wiht the condition of the former cell. Rafael Excel Discussion (Misc queries) 7 December 22nd 04 04:53 AM
condition format for surrounding cells little rusty with excel Excel Discussion (Misc queries) 1 December 9th 04 07:35 AM


All times are GMT +1. The time now is 02:39 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"