Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
Dinesh
 
Posts: n/a
Default Tranferring names defined in one excel workbook to another workboo

I defined some names using name manager in One Excel workbook . i want to
transfer all the namespaces into another workbook.
How can i do that ?
  #2   Report Post  
Posted to microsoft.public.excel.misc
JLatham
 
Posts: n/a
Default Tranferring names defined in one excel workbook to another workboo

Both workbooks need to have same sheet names in order for this to work
without error when you try to reference the named ranges in the second
workbook. Put this code in the workbook with the names already defined.
Open up the second workbook and then run the macro:

Sub CopyNamedNamedRanges()
Dim AnyName As Object

For Each AnyName In ThisWorkbook.Names
Workbooks("Book2.xls").Names.Add AnyName.Name, AnyName.RefersTo, True
Next

End Sub

Change "Book2.xls" to the name of the workbook you need to move the named
ranges into.


"Dinesh" wrote:

I defined some names using name manager in One Excel workbook . i want to
transfer all the namespaces into another workbook.
How can i do that ?

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
excel exits unexpectedly or hangs the second time I open workbook r_m_i Excel Discussion (Misc queries) 0 February 9th 06 10:14 PM
Workbook fails to open - Excel 2003 nc Excel Discussion (Misc queries) 1 February 2nd 06 06:33 PM
Excel Spreadsheet from Access. List of names changes as names are Gordy w/Hi Expectations Excel Discussion (Misc queries) 1 October 21st 05 03:30 AM
How to refresh a Excel workbook with pivot & ADO query report in batch mode Karen Middleton Excel Discussion (Misc queries) 1 April 29th 05 02:05 PM
Automate Excel to powerpoint - Graphs along with Datasheet (not workbook) Hari Prasadh Charts and Charting in Excel 4 February 17th 05 02:44 PM


All times are GMT +1. The time now is 10:40 PM.

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

About Us

"It's about Microsoft Excel"