Home |
Search |
Today's Posts |
#1
![]() |
|||
|
|||
![]()
Hello from Steved
Please in Column A how do i find the last row with data using a macro. At the moment I'm on Row 1108 so can a macro find the next row in this case 1109 biut by tonight I'll be on row 1150, so in this case would it goto row 1151. Thankyou Very Much. |
#2
![]() |
|||
|
|||
![]()
Hi Steved
You can use this to select the next empty cell Sub test() Range("A" & Rows.Count).End(xlUp)(2).Select End Sub This will select the last cell with data Range("A" & Rows.Count).End(xlUp).Select -- Regards Ron de Bruin http://www.rondebruin.nl "Steved" wrote in message ... Hello from Steved Please in Column A how do i find the last row with data using a macro. At the moment I'm on Row 1108 so can a macro find the next row in this case 1109 biut by tonight I'll be on row 1150, so in this case would it goto row 1151. Thankyou Very Much. |
#3
![]() |
|||
|
|||
![]()
Assuming the data's in sheet1, this will return the next empty cell in
column A ThisWorkbook.Sheets("Sheet1").Range("A65536").End( xlUp).Offset(1, 0) HTH Alan P. "Steved" wrote in message ... Hello from Steved Please in Column A how do i find the last row with data using a macro. At the moment I'm on Row 1108 so can a macro find the next row in this case 1109 biut by tonight I'll be on row 1150, so in this case would it goto row 1151. Thankyou Very Much. |
#4
![]() |
|||
|
|||
![]()
Steve
' note that NextRow will be 2 if no data is present Dim NextRow As Long NextRow = Range("A" & Rows.Count).End(xlUp).Offset(1, 0).Row MsgBox NextRow Regards Trevor "Steved" wrote in message ... Hello from Steved Please in Column A how do i find the last row with data using a macro. At the moment I'm on Row 1108 so can a macro find the next row in this case 1109 biut by tonight I'll be on row 1150, so in this case would it goto row 1151. Thankyou Very Much. |
#5
![]() |
|||
|
|||
![]()
Sub LastCell()
Dim LastCellRow As Long Dim FirstOpenRow As Long LastCellRow = Cells(Rows.Count, "A").End(xlUp).Row FirstOpenRow = LastCellRow + 1 MsgBox FirstOpenRow End Sub --- HTH Jason Atlanta, GA -----Original Message----- Hello from Steved Please in Column A how do i find the last row with data using a macro. At the moment I'm on Row 1108 so can a macro find the next row in this case 1109 biut by tonight I'll be on row 1150, so in this case would it goto row 1151. Thankyou Very Much. . |
#6
![]() |
|||
|
|||
![]()
I would like to thankyou all.
Cheers. -----Original Message----- Hello from Steved Please in Column A how do i find the last row with data using a macro. At the moment I'm on Row 1108 so can a macro find the next row in this case 1109 biut by tonight I'll be on row 1150, so in this case would it goto row 1151. Thankyou Very Much. . |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
I entered 11/22/2004 in excel workbook and it keeps changing to ## | Excel Worksheet Functions | |||
Warn if already entered | Excel Worksheet Functions | |||
finding the second largest number in a list | Excel Discussion (Misc queries) | |||
micosoft excel dates entered but changed to sequencial numbers ho. | Excel Worksheet Functions | |||
showing the # of times an item is entered in a column | Excel Worksheet Functions |