
Using a ‘for’ loop with the CurrentRegion property in Excel
If you don’t know the boundaries of the range you want to loop through, you can use the CurrentRegion property to return the range that surrounds the active cell. For example, the following procedure, when run from a worksheet, loops through the range that surrounds the active cell, setting to 0 all values less than 0.01.
