Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 343
Default Hide Column AD

I am looking for the ability (in vba) to hide column AD without actually
selecting it.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Hide Column AD

activesheet.range("AD1").entirecolumn.hidden = true

"Patrick C. Simonds" wrote:

I am looking for the ability (in vba) to hide column AD without actually
selecting it.


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,934
Default Hide Column AD

Here is another way...

ActiveSheet.Columns("AD").Hidden = True

By the way, the sheet doesn't have to be active to do this. Assuming Sheet1
is the ActiveSheet, here is how to hide Column AD on Sheet2...

Worksheets("Sheet2").Columns("AD").Hidden = True

or, if you want to do it via a variable...

WSname = "Sheet2"
Worksheets(WSname).Columns("AD").Hidden = True

--
Rick (MVP - Excel)


"Patrick C. Simonds" wrote in message
...
I am looking for the ability (in vba) to hide column AD without actually
selecting it.


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 Column If Usedrange of Column ISBLANK Follow-up [email protected] Excel Discussion (Misc queries) 1 April 12th 09 10:00 PM
Hide Column If Usedrange of Column ISBLANK [email protected] Excel Discussion (Misc queries) 4 April 12th 09 09:47 PM
hide one column skip two column and unhide one of 11 JLGWhiz Excel Programming 0 January 11th 07 02:59 AM
hide column bigpalooka Excel Programming 0 November 14th 06 05:18 PM
Hide column or row based on a cell in the column or row? SacGuy Excel Discussion (Misc queries) 0 January 24th 06 06:51 PM


All times are GMT +1. The time now is 11:01 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"