Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Shooter
 
Posts: n/a
Default macro to hide columns

My spreadsheet has data in cells A1:G20. I would like to create a macro to
hide columns D, E, F&G. Similarly, I would like to create a macro to unhide
the same columns. I appretiate your help with code to do this.
--
Shooter
  #2   Report Post  
Ron de Bruin
 
Posts: n/a
Default

Try

ActiveSheet.Range("D1:G1").EntireColumn.Hidden = True

Set it to false to unhide them


--
Regards Ron de Bruin
http://www.rondebruin.nl


"Shooter" wrote in message ...
My spreadsheet has data in cells A1:G20. I would like to create a macro to
hide columns D, E, F&G. Similarly, I would like to create a macro to unhide
the same columns. I appretiate your help with code to do this.
--
Shooter



  #3   Report Post  
Anne Troy
 
Posts: n/a
Default

Shooter: This is a no-brainer that can be recorded. See how to record a
macro he
http://www.officearticles.com/excel/...soft_excel.htm
************
Anne Troy
www.OfficeArticles.com


"Shooter" wrote in message
...
My spreadsheet has data in cells A1:G20. I would like to create a macro to
hide columns D, E, F&G. Similarly, I would like to create a macro to
unhide
the same columns. I appretiate your help with code to do this.
--
Shooter



Reply
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
Hide / Unhide columns and rows PaulM Excel Discussion (Misc queries) 8 September 6th 07 12:14 AM
Macro to Synchronize data frm svrl workbooks & columns to 1 workbo jbsand1001 Excel Discussion (Misc queries) 1 April 28th 05 10:42 AM
Removing columns (not hide or white-out). TrishDB Excel Worksheet Functions 8 April 28th 05 01:24 AM
I used the "hide" feature on 3 columns - now I cannot get them b. Patinak New Users to Excel 6 March 12th 05 06:18 PM
macro to copy columns to sheet Es Excel Discussion (Misc queries) 1 March 7th 05 02:03 PM


All times are GMT +1. The time now is 07:35 PM.

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

About Us

"It's about Microsoft Excel"