(xlDown) not working properly!

  • Thread starter Thread starter aapp81
  • Start date Start date
A

aapp81

i have columns A2:T2 selected and then i do this:
Range(Selection, Selection.End(xlDown)).Select
but it only selects up to the last row in column T but other cols ar
longer...
is there anyway to fix this so that it selects down to the longest col
 
aapp81

It should select down to the last value in column A, not T. Anyway, try
this

Selection.CurrentRegion.Select

and see if that doesn't give you the proper range.

--
Dick Kusleika
MVP - Excel
www.dicks-clicks.com
Post all replies to the newsgroup.

aapp81 said:
i have columns A2:T2 selected and then i do this:
Range(Selection, Selection.End(xlDown)).Select
but it only selects up to the last row in column T but other cols are
longer...
is there anyway to fix this so that it selects down to the longest col?


------------------------------------------------



~~Now Available: Financial Statements.xls, a step by step guide to
creating financial statements
 
Dick said:
*aapp81

It should select down to the last value in column A, not T. Anyway
try
this

Selection.CurrentRegion.Select

and see if that doesn't give you the proper range.
*

yeah, i thought about doing that but i have headings in A1:T1 and doin
"currentregion" selects them as well... and i want it to start fro
row
 
set rng = selection.CurrentRegion
if rng.row = 1 then _
set rng = rng.offset(1,0).Resize(rng.rows.count-1)

rng.Select

--
Regards,
Tom Ogilvy


aapp81 said:
yeah, i thought about doing that but i have headings in A1:T1 and doing
"currentregion" selects them as well... and i want it to start from
row2


------------------------------------------------



~~Now Available: Financial Statements.xls, a step by step guide to
creating financial statements
 
Here's one way...

With Selection
.Resize(.CurrentRegion.Rows.Count - .Row + 1, _
.CurrentRegion.Columns.Count).Select
End With


Regards,
Vic Eldridge
 
Hey Vic ... long time no see!

Regards,

Vasant.

Vic Eldridge said:
Here's one way...

With Selection
.Resize(.CurrentRegion.Rows.Count - .Row + 1, _
.CurrentRegion.Columns.Count).Select
End With


Regards,
Vic Eldridge


aapp81 <[email protected]> wrote in message
creating financial statements
 
Hey Vic ... long time no see!
Regards,

Vasant.


Howdy Vasant.

Yeah it's been a while. I wonder how many Application.ScreenUpdating
= False's I missed out on. ;-)

I see you've been crowned an MVP. Well Done !


Regards,
Vic Eldridge
 
Back
Top