LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #14   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Another Speed Problem!

Because XL 97 works differently when you do an offset with a discontinuous
range.

--
Regards,
Tom Ogilvy

Stu wrote in message
...
Why do some of these not work in XL 97? Is there any reason for that?
Buts its ok to me seeing as I use XL2002.

Thanks
--
Stu


"Tom Ogilvy" wrote in message
...
Note that this won't work in Excel 97. May not be an issue, but

important
to know.

--
Regards,
Tom Ogilvy

Dana DeLouis wrote in message
...
Not sure if it's faster, but would any ideas here help? I hope I got

the
logic right.

Sub YearHide()
'// Dana DeLouis
'// If a cell is blank, hide the row below

Dim rng As Range
Dim Remember As Boolean
Dim nRows As Long '# of Rows per area

Remember = Application.ScreenUpdating
Application.ScreenUpdating = False

On Error Resume Next
For Each rng In
Range("B3,B28,B52,B76,B100,B124,B148,B172,B196,B22 0,B244,B268").Cells
nRows = IIf(rng.Row = 3, 19, 18)
rng.Resize(nRows + 1).EntireRow.Hidden = False
rng.Resize(nRows).SpecialCells(xlCellTypeBlanks).O ffset(1,
0).EntireRow.Hidden = True
Next rng

Application.ScreenUpdating = Remember
End Sub

--
Dana DeLouis
Using Windows XP & Office XP
= = = = = = = = = = = = = = = = =


"Stu" wrote in message
...
Hey guys, I have some more code that takes its time being ran, any

ideas
on
how to speed it up?

Here's the code:

Sub Year()

Dim Rng As Range
For Each Rng In




Range("B3:B21,B28:B45,B52:B69,B76:B93,B100:B117,B1 24:B141,B148:B165,B172:B18
9,B196:B213,B220:B237,B244:B261,B268:B285")
Rng(2, 1).EntireRow.Hidden = (Rng.Value = "")
Next Rng

End Sub

Thanks
---
Stu










 
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
low speed problem peyman Excel Discussion (Misc queries) 3 August 29th 07 03:42 AM
Excel 2007 Speed Problem JohnnyG Excel Discussion (Misc queries) 5 May 24th 07 04:44 PM
VBA Speed up sparx Excel Discussion (Misc queries) 2 April 29th 06 04:59 PM
Can you speed UP drag speed? Ryan W Excel Discussion (Misc queries) 1 October 24th 05 06:09 PM
program speed problem chris[_3_] Excel Programming 1 September 11th 03 02:05 AM


All times are GMT +1. The time now is 03:00 AM.

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"