Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Find The Last Used Row
Greetings,
I am trying to display the last row in column A in a MsgBox with this code on a CommandButton with this code: ______________________________________________ Private Sub CommandButton1_Click() Dim lLastRow As Long lLastRow = Sheets("CustList").Cells("65536", _ "A").End(xlUp).Rows.Offset(1, 0) MsgBox "Last row plus 1 = " & lLastRow End Sub ______________________________________________ The MsgBox says "Last Row plus 1 = 0" There are 2913 rows in column A.. Can anyone see what is wrong with this code? Any help will be appreciated. -Minitman |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Find rows with a common item and find or highlight difference | Excel Programming | |||
Find and Replace - delete the remainder of the text in the cell after my Find | Excel Programming | |||
Despite data existing in Excel 2002 spreadsheet Find doesn't find | Excel Discussion (Misc queries) | |||
find and delete duplicate entries in two columns or find and prin. | Excel Programming | |||
find and delete text, find a 10-digit number and put it in a textbox | Excel Programming |