LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,290
Default adding range name that includes a sheet name

Try... RefersTo:="=" & strRangeAddress
--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware



"KarenH"
wrote in message
I am attempting to add ranges to a sheet based on another spreadsheet.

I have named the range name strRangeName, and the corresponding range
address as strRangeAddress. However, the range addresses will include
worksheet names as well as ranges, for example: 'S-S-0'!$B$12:$D$63

The following statement in my code is failing:
ActiveWorkbook.Sheets(strSheetName).Names.Add Name:=strRangeName,
RefersTo:=strRangeAddress
I'm fairly certain it's due to the range name, but I"m not sure of a way
around it.
Any ideas? Thanks in advance

 
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
countifs criteria includes date range JayH Excel Worksheet Functions 4 February 3rd 10 01:19 AM
Auto-filter includes too much range Atreides Excel Discussion (Misc queries) 4 May 15th 08 01:23 AM
=max(range includes #N/As) David Excel Worksheet Functions 3 September 14th 05 05:00 PM
How do I sum a range which includes the "#N/A" VLOOKUP return valu Sailor Excel Worksheet Functions 6 May 9th 05 08:46 AM
How to specify a Range which includes an integer variable Hotbird[_3_] Excel Programming 4 May 7th 04 02:38 PM


All times are GMT +1. The time now is 06:30 AM.

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"