• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Dim variable as range (last row full of blanks)

Hi,

Im sure this is quite a simple question that I need help on.

Say I have a table with 2 columns (A & B) that is 1000 rows long - column A has values in every row up but column B only has values in some of the rows.

I am trying to define the last row on column B (say it is row 8015) as a range but not sure how to do this ?

Dim LastRowOnColB as Range
Range = .... (this is where I draw the blank)

Any suggestions would be greatly appreciated.
 
1. Is it actually a Table, or just a two column range?
2. Do you want to refer to the last cell in column B that has a value, or the last cell in column B where column A has a value, or something else?
 
1. Just a two column range, my bad!!
2. Just the last cell in column B, regardless of whether or not column A has a value (although with this dataset, there will always be a value in column A)

Thanks
 
Back
Top