LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Hiding Rows-Macro or Autofilter

I am trying to determine the best way to hide rows based on a certain
criterial. In sheet 1 of my model, I have a column of cells E63:E102
with formulas that either equal zero, or a value greater than zero. I
would like to hide the rows where the value is equal to zero. I have
used a macro from other worksheets but It does not seem to be working-
not even slowly- in this model. I think maybe my file size is too
large? (almost 4M). The macro I have been currently using is,
Dim c As Range
For Each c In Range("e63", Range("e102").End(xlUp))
If c.value = 0 Then
c.EntireRow.Hidden = True
Else: c.EntireRow.Hidden = False
End If
Next c
End Sub

I am not sure if this is the best one to be using. If my results are
slow, should I switch to an autofilter macro. I would like to have it
as a macro so I can just refresh the range as numbers get added or
deleted with a click of a button. Any suggestions?
 
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 for hiding rows Khardy3352 New Users to Excel 4 February 11th 09 07:41 PM
Macro for hiding rows Linda Excel Discussion (Misc queries) 2 February 1st 06 09:26 PM
Macro for hiding rows Luke Excel Discussion (Misc queries) 22 December 24th 05 03:40 PM
hiding rows with a macro Lee Excel Programming 3 August 27th 05 11:11 PM
hiding rows using macro Tom Ogilvy Excel Programming 1 August 27th 04 12:51 AM


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