View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Per Jessen Per Jessen is offline
external usenet poster
 
Posts: 1,533
Default Finding a used / filled rows

Hi

Try this:

Sub FindUsedRow()
TargetCol = "C"
If Range(TargetCol & "1").Value = "" Then
UsedRow = Range(TargetCol & "1").End(xlDown).Row
Else
UsedRow = 1
End If
Debug.Print UsedRow
End Sub

Regards,
Per

"ogopogo5" skrev i meddelelsen
...
How can I write a sub-routine that will look for a row that is used /
filled. I.E. rows C1 to C8 are empty and it keep skipping the empty rows
until it finds a row that is used / filled. In this case row C9 is used.



*** Sent via Developersdex http://www.developersdex.com ***