RESIZE range to exclude totals row

M

MikeF

Simply need to copy the following range *excluding* the totals row, which is
always the bottom row.
Here's one of numerous attempts that doesn't work:

Range("ak1").Select
Range(Selection, Selection.End(xlToRight)).Select
Range(Selection, Selection.End(xlDown)).Select
Selection.Resize(Rows.Count - 1, Columns.Count).Select

Any assistance would be greatly appreciated.
Thanx.
- Mike
 
M

MikeF

Bob,

Thanx for the reply.

The row part of it works fine, but it's taking *all* the columns to the
right, not just the 5, 6, 7, or whatever is there.
Is that happening on your end as well?
 
B

Bob Phillips

Is this better?

With Range("ak1")

.Resize(.End(xlDown).Row - 1, .End(xlToRight).Column - .Column() +
1).Select
End With
 
M

MikeF

Yes, that works.
Thank you.

Bob Phillips said:
Is this better?

With Range("ak1")

.Resize(.End(xlDown).Row - 1, .End(xlToRight).Column - .Column() +
1).Select
End With

--
__________________________________
HTH

Bob
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top