LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 536
Default Return last row no. of column with blanks at top

I have column F that the data starts in F5 to F?
I want the last row number.
All these examples return F5, one errors out.

I can't believe I don't have an example in cheat sheet.

Thanks.
Howard

lrC = Sheets("Data").Cells(Rows.Count, 6).End(xlUp).Row

lrC = Range("F5:F" & Range("F5").End(xlDown)).Row

If WorksheetFunction.CountA(Cells) 0 Then
lrC = Cells.Find(What:="*", After:=[F5], _
SearchOrder:=xlByRows, _
SearchDirection:=xlPrevious).Row
End If

MsgBox lrC
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Concatenate with carriage return- how to remove blanks? cindyc Excel Worksheet Functions 3 September 17th 08 10:31 PM
Return unique number, skip blanks lleytte Excel Worksheet Functions 6 June 26th 08 11:59 PM
Return Unique Records ... No Blanks Ken Excel Discussion (Misc queries) 4 September 6th 07 04:31 AM
selecting cells which contain formulas but return blanks hot dogs Excel Discussion (Misc queries) 3 September 12th 06 12:07 PM
Replace all non blanks in a column with column header hnyb1 Excel Discussion (Misc queries) 3 April 18th 06 05:39 PM


All times are GMT +1. The time now is 03:56 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"