Thread
:
Hide unhide non-contiguous columns
View Single Post
#
4
Posted to microsoft.public.excel.programming
Don Guillett
external usenet poster
Posts: 10,124
Hide unhide non-contiguous columns
Sub togglehiddencolumns()
Range("G:G,J:J,P:P,R:R").EntireColumn.Hidden = Not _
Range("G:G,J:J,P:P,R:R").EntireColumn.Hidden
End Sub
--
Don Guillett
Microsoft MVP Excel
SalesAid Software
"Saintsman" wrote in message
...
I use the following code to hide/unhide a range of cells using a tick box
With Columns("O:W")
.Hidden = Not .Hidden
End With
I want to do exactly the same for columns G,J,P,R ie if they are hidden
then
unhide them, if they are not hidden then hide them
Any help appreciated
Reply With Quote
Don Guillett
View Public Profile
Find all posts by Don Guillett