Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,441
Default Selecting range programmatically

Barb,

You need to activate a sheet before you can select a range. Try:

Sheets(Summary.Name).Activate
Sheets(Summary.Name).Cells(Sheets(Summary.Name).Ce lls(Rows.Count, _
"A").End(xlUp).Row + 1, 12).Select


HTH,
Bernie
MS Excel MVP


"Barb Reinhardt" wrote in message
...
I've got the following to define a value on another worksheet and it works.

Sheets(Summary.Name).Cells(Sheets(Summary.Name).Ce lls(Rows.Count,
"A").End(xlUp).Row + 1, 1).Value = Target.Offset(0, 6 - Target.Column).Value

What I want to do is select a range including this cell up to 12 columns to
the right to put a border on it. I've tried this:

Sheets(Summary.Name).Cells(Sheets(Summary.Name).Ce lls(Rows.Count,
"A").End(xlUp).Row + 1, 12).Select

I get "Select method of range class failed"

Thanks




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Programmatically selecting first worksheet Barb Reinhardt Excel Programming 1 July 14th 06 12:38 AM
Programmatically selecting first worksheet Barb Reinhardt Excel Programming 4 July 13th 06 11:42 PM
Selecting Embedded charts in Active Sheets programmatically Barb Reinhardt Charts and Charting in Excel 5 January 15th 06 02:36 PM
Selecting most of very many programmatically Tony Rizzo[_2_] Excel Programming 2 July 27th 05 08:50 PM
Selecting Rows Programmatically Aaron Lampkin Excel Programming 1 September 5th 03 01:42 PM


All times are GMT +1. The time now is 06:33 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"