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: 11,123
Default Named ranges

Hi Shawn

You can use the same name more then one time.
This example will add the name ron in all your sheets

Sub Give_name_on_all_sheets()
Dim Sh As Worksheet
For Each Sh In ThisWorkbook.Worksheets
Sh.Range("a1").Name = Sh.Name & "!ron"
Next
Sheets(1).Select
End Sub

in a cell use =ron to get the value from cell A1 on that sheet

--
Regards Ron de Bruin
http://www.rondebruin.nl


"Shawn" wrote in message ...
Hi

Hi

I just noticed something that was very strange and I need to find out whether or not this is expected. It looks like multiple

named ranges with exactly the same name can exist in one workbook. This means that different cells are referenced at different
situations if this named range is used in formulas. My understanding was that range names have to be unique within a workbook. Which
behaviour is expected?

In addition, if you look through the Insert|Name|Define menu option only one reference shows for a particular duplicated named

range.

This may sound like an observation that is not very important but it is very important for what I'm attempting to do.

Thanks a lot

Shawn



 
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
Named Ranges James Hamilton Excel Discussion (Misc queries) 1 March 15th 07 11:25 PM
Like 123, allow named ranges, and print named ranges WP Excel Discussion (Misc queries) 1 April 8th 05 06:07 PM
Named Ranges Gary T Excel Worksheet Functions 2 December 27th 04 02:28 AM
Using Named Ranges in VB Rocky Bryant Excel Programming 4 October 1st 03 09:44 PM
Named Ranges and VBA Add-ins Mark[_19_] Excel Programming 1 September 17th 03 08:39 PM


All times are GMT +1. The time now is 07:36 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"