Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 4
Default Tab referenced to a cell

I am using Excel 2007. I would like to use the content of a cell (A1) to
also be the name of my tab at the bottom of the sheet.
Example: In cell A1, it contains the name: BOB.
I would like the name of the tab at the bottom of the sheet to reflect what
is in cell A1as BOB.
Can this be done?
Thanks


  #2   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 22,906
Default Tab referenced to a cell

All tabs or just one tab?

Event code for all tabs....................

Place in Thisworkbook module.

Private Sub Workbook_SheetCalculate(ByVal sh As Object)

'for just one sheet change the event type to
'Private Sub Worksheet_Calculate()
'and place in the sheet module

On Error GoTo endit
Application.EnableEvents = False
With ActiveSheet.Range("A1")
If .Value < "" Then
ActiveSheet.Name = .Value
End If
End With
endit:
Application.EnableEvents = True
End Sub

When a calculation takes place on any sheet, the sheet name will reflect
what is in A1 of that sheet.

If same name as other sheet or contains invalid characters the event will
simply end...............no change in sheet name.


Gord Dibben MS Excel MVP


On Wed, 28 Apr 2010 17:52:44 -0400, "Charles Eaves"
wrote:

I am using Excel 2007. I would like to use the content of a cell (A1) to
also be the name of my tab at the bottom of the sheet.
Example: In cell A1, it contains the name: BOB.
I would like the name of the tab at the bottom of the sheet to reflect what
is in cell A1as BOB.
Can this be done?
Thanks


  #3   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 4
Default Tab referenced to a cell

One tab.
As always, thank you very much!!!!!!!!
"Gord Dibben" <gorddibbATshawDOTca wrote in message
...
All tabs or just one tab?

Event code for all tabs....................

Place in Thisworkbook module.

Private Sub Workbook_SheetCalculate(ByVal sh As Object)

'for just one sheet change the event type to
'Private Sub Worksheet_Calculate()
'and place in the sheet module

On Error GoTo endit
Application.EnableEvents = False
With ActiveSheet.Range("A1")
If .Value < "" Then
ActiveSheet.Name = .Value
End If
End With
endit:
Application.EnableEvents = True
End Sub

When a calculation takes place on any sheet, the sheet name will reflect
what is in A1 of that sheet.

If same name as other sheet or contains invalid characters the event will
simply end...............no change in sheet name.


Gord Dibben MS Excel MVP


On Wed, 28 Apr 2010 17:52:44 -0400, "Charles Eaves"
wrote:

I am using Excel 2007. I would like to use the content of a cell (A1) to
also be the name of my tab at the bottom of the sheet.
Example: In cell A1, it contains the name: BOB.
I would like the name of the tab at the bottom of the sheet to reflect
what
is in cell A1as BOB.
Can this be done?
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
bold text of referenced cell show in formula cell zabcikranch Excel Worksheet Functions 1 February 2nd 10 07:42 PM
Return Results of a cell based on cell referenced in a cell Drew Excel Worksheet Functions 4 September 3rd 09 06:19 PM
Change Text Color in one cell based upon entry in referenced cell Tee Excel Discussion (Misc queries) 3 September 12th 08 10:07 PM
The absolute referenced cell does not move when source cell moves johnc Excel Worksheet Functions 2 May 8th 06 06:33 PM
How do I double click a cell and jump to cell's referenced cell JerryJuice Excel Discussion (Misc queries) 2 September 10th 05 10:24 PM


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