Layman,
For 5000 rows, the Union method is likely to lose its advantage.
Set a timer on it and try both ways.
--
HTH
Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
"Layman " wrote in message
...
Hi!
My first post here..
I have to write 5000 rows to an Excel spreadsheet.
Each row is distinct, and is received from a server. The writing of the
rows themselves is not a problem however. (I'm setting the row range to
a variant array)
Here is my question.. I also have to color the row and lock it down,
depending on the information in the row itself. Currently, we check the
criteria of the row at the time when we add it onto the sheet, and lock
it and color it at that point. Naturally screen updates are turned off
for the processing of all 5000 rows!
However, I recently thought of another way to do it, where I have a
LockDownRange which I union with the row range if it meets the lock
down criteria. Then after processing all 5000 rows, I call one single
lock down on the LockDownRange. Ditto with the ColorRange
Is the second method going to be any faster?
---
Message posted from http://www.ExcelForum.com/