ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   find last row and select whle row for format (https://www.excelbanter.com/excel-discussion-misc-queries/68897-find-last-row-select-whle-row-format.html)

saziz

find last row and select whle row for format
 

Hi All,

Here is the code I am trying to select last row.

iRow = .Cells(.Rows.Count, 2).End(xlUp).Row
.Cells(iRow, 1).Select

It just select last cell in col. A. I like to select the whole row.
Any help please
Thank you
Syed.


--
saziz
------------------------------------------------------------------------
saziz's Profile: http://www.excelforum.com/member.php...fo&userid=6350
View this thread: http://www.excelforum.com/showthread...hreadid=507505


Bob Phillips

find last row and select whle row for format
 
iRow = .Cells(.Rows.Count, 2).End(xlUp).Row
Rows(iRow).Select

--

HTH

Bob Phillips

(remove nothere from the email address if mailing direct)

"saziz" wrote in
message ...

Hi All,

Here is the code I am trying to select last row.

iRow = .Cells(.Rows.Count, 2).End(xlUp).Row
Cells(iRow, 1).Select

It just select last cell in col. A. I like to select the whole row.
Any help please
Thank you
Syed.


--
saziz
------------------------------------------------------------------------
saziz's Profile:

http://www.excelforum.com/member.php...fo&userid=6350
View this thread: http://www.excelforum.com/showthread...hreadid=507505




saziz

find last row and select whle row for format
 

I was totally ignoring cell/row thing.
Thank you
Syed


--
saziz
------------------------------------------------------------------------
saziz's Profile: http://www.excelforum.com/member.php...fo&userid=6350
View this thread: http://www.excelforum.com/showthread...hreadid=507505



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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com