Thread
:
Can anyone help me figure this out?
View Single Post
#
4
Posted to microsoft.public.excel.programming
Myrna Larson
external usenet poster
Posts: 863
Can anyone help me figure this out? The Magic Man Can
If the change was to hide all rows at the end, instead of one at a time,
that's the reason: operations like that are very time-consuming, and it takes
very little more time to carry it out on several rows than on one.
On 6 Oct 2004 15:14:43 -0700,
(ski) wrote:
Norman,
You are a super magical man :)
That cut the run time to less than half a min
Wish I knew why
This is what I ended up with
thanks again
Shaun
Dim hideList As Range
Set hideList = Rows(Rows.Count)
i = 2
j = 2
Do Until Cells(i, LAST) = ""
If DateDiff("d", Cells(i, LAST), Now()) <= age Then
If Not Cells(i, NATL) = Cells(j, NATL) Then
Set hideList = Union(hideList, Rows(i))
End If
Else
j = i
End If
i = i + 1
Loop
hideList.EntireRow.Hidden = True
Reply With Quote
Myrna Larson
View Public Profile
Find all posts by Myrna Larson