0
Thanks

A few words of thanks would be greatly appreciated.

Excel/VBA - Get the row number of the first blank cell



Issue


I need a code to fetch the row number of first blank cell in a column.

Solution


dim i as integer     
i=1     
While Sheets(5).Cells(i, 2) <> ""     
    i = i + 1     
Wend     
MsgBox i 'num of the blank line     

Thanks to Polux31 for this tip.
0
Thanks

A few words of thanks would be greatly appreciated.

Ask a question
CCM is a leading international tech website. Our content is written in collaboration with IT experts, under the direction of Jeff Pillou, founder of CCM.net. CCM reaches more than 50 million unique visitors per month and is available in 11 languages.

Published by . Latest update on by jak58.

This document, titled "Excel/VBA - Get the row number of the first blank cell," is available under the Creative Commons license. Any copy, reuse, or modification of the content should be sufficiently credited to CCM (https://ccm.net/).

0 Comments