LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #4   Report Post  
Posted to microsoft.public.excel.programming
DS DS is offline
external usenet poster
 
Posts: 117
Default VBA to rename sheet WITHIN Excel

Thanks Tom, building it up as a string and referencing the string hadn't
occurred to me - I'll use that. And double thanks that I'm no longer going to
drive myself insane trying to do something that can't be done!


"Tom Ogilvy" wrote:

Names are limited to a range. So you can not name a worksheet or a
workbook. You can define a name to hold a string and then use that string
with indirect to build a range reference, but the string would be static and
not be automatically changed if the sheet name or workbook name were to be
changed. (note: indirect only works when creating references to
locations in open workbooks).

--
Regards,
Tom Ogilvy

"DS" wrote in message
...
Hi,
I'm looking to be able to rename a separate workbook within excel, in the
same way as a range can be named using the line:

ActiveWorkbook.Names.Add "ThisRange", RefersTo:=Selection

This is so that formulae within an excel sheet can reference to the named
sheet (depending on previously determined parameters, the named sheet

could
be one of a number of data sources), using COUNTIF etc functions.

Many Thanks in Advance
Mike




 
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
how do i rename a sheet if the rename tab is inactive? Nelson Excel Worksheet Functions 1 March 3rd 10 10:28 AM
rename sheet tabs in excel blantyreson Excel Discussion (Misc queries) 2 August 22nd 07 06:31 PM
How to rename Excel Sheet with more characters? Billy316 Excel Discussion (Misc queries) 4 July 20th 05 05:11 AM
I cannot rename my excel sheet? Cissy Excel Worksheet Functions 1 April 3rd 05 05:50 AM
How can i trap the rename event of an excel sheet? bmm Excel Programming 4 August 10th 04 03:51 PM


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