lezawang
Well-known Member
- Joined
- Mar 27, 2016
- Messages
- 1,805
- Office Version
- 2016
- Platform
- Windows
Hi
I understand to find the last empty row, I can use this line of code
but now I just read an article and the following line is used to find the last row
I do not understand how the line above can find the last row! I understand countA() function is used to count how many cells in a range which has value (text/number). But I can not see how that function is used to find the last empty row. Any help would be very much appreciate. Thanks.
I understand to find the last empty row, I can use this line of code
Code:
x = Cells(Rows.Count, 1).End(xlUp).Row
but now I just read an article and the following line is used to find the last row
Code:
x = WorksheetFunction.CountA(Range("A:A")) + 1
I do not understand how the line above can find the last row! I understand countA() function is used to count how many cells in a range which has value (text/number). But I can not see how that function is used to find the last empty row. Any help would be very much appreciate. Thanks.