CurrentRegion Property in Excel VBA
This example illustrates the CurrentRegion property in Excel VBA. The current region is a range bounded by any combination of blank rows and blank columns. Can you find the current region of cell A1?
Place a command button on your worksheet and add the following code line:
Result when you click the command button on the sheet:
Here is another example. Can you find the current region of cell B3?
Code:
Result:
The value 1 in row 1 has no influence on the current region of cell B3. Row 2 is empty!
If you're new here, welcome to Excel Easy! Join over 1 million monthly Excel learners. You can find popular courses here: Data Analysis in Excel and Excel VBA.