Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default Hide rows within a range IF...

Greetings,
Newbie here so any help is appreciated.

Within the active worksheet, within the row range of Row 7 thru Row 1004, if
the value in Column CK for that Row is = 0, then hide the entire row.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10,124
Default Hide rows within a range IF...


One way
sub hideifzero()
for i=1004 to 2 step-1
if cells(i,"ck")=0 then rows(i).hidden=true
next i
end sub
--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"drumsab" wrote in message
...
Greetings,
Newbie here so any help is appreciated.

Within the active worksheet, within the row range of Row 7 thru Row 1004,
if
the value in Column CK for that Row is = 0, then hide the entire row.


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default Hide rows within a range IF...

Thanks.

My spreadsheet is fairly big. Any way to make the "hiding rows" go faster
than it does with this code?

"Don Guillett" wrote:


One way
sub hideifzero()
for i=1004 to 2 step-1
if cells(i,"ck")=0 then rows(i).hidden=true
next i
end sub
--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"drumsab" wrote in message
...
Greetings,
Newbie here so any help is appreciated.

Within the active worksheet, within the row range of Row 7 thru Row 1004,
if
the value in Column CK for that Row is = 0, then hide the entire row.



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
Macro to hide rows with zero in specifc column range David Excel Discussion (Misc queries) 1 April 20th 10 08:10 PM
Hide all rows within a range except one? mevetts Excel Discussion (Misc queries) 2 December 23rd 05 09:27 PM
Hide columns & rows that contain "0" or blank in a range of cells lw new guest Excel Worksheet Functions 0 August 18th 05 04:27 PM
Hide blank rows in a range trussman Excel Programming 0 February 18th 05 02:50 PM
Hide Unused Cols & Rows in a Range Bob Maloney Excel Programming 2 July 31st 03 12:39 PM


All times are GMT +1. The time now is 10:00 PM.

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"