One of the reasons Worksheet_Change might bog down your system is because you're making changes to the Worksheet from within the Worksheet_Change event. As these changes trigger the Worksheet_Change event... you can end up with a considerable amount of overhead, as it recursively calls itself. Excel eventually detects this (sometimes), and stops the process, but it eats up considerable CPU.
In the future, if you decide to use the worksheet change macro, put the following code around the section where you make changes to your worksheet:
Application.EnableEvents = False
[code to make changes]Please Login or Register to view this content.[/CODE]
As you can see, this is a circular reference. It will need to be an array formula because B1 (where you enter the formula) has an initial value of 0, which can screw things up... ie. it takes 0 as the value, no matter what is in A1.
Maximums are easier, assuming you don't have negatives (that is, if you have negatives, you'll have to set up something like the above to avoid 0 values):
As to a VBA solution, I'd be inclined to use the Worksheet_Change macro, but that doesn't meet your specs.
Scott
Bookmarks