Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 147
Default Naming of tabs from data in a worksheet

Hello, I've looked for a post on this and in Excel help but drawing a blank.
Hoping one of you might have an answer for me.

Is there a formula that will insert the value on spreadsheet tab into a
cell€¦.or vice versa - the value in a cell into the tab?

For instance, I would like to put a name in cell A2 and have the tab for
that worksheet be the same as whatever the value in A2 is.

Hope that makes sense.

Regards,

Christine
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,501
Default Naming of tabs from data in a worksheet

Hi,

You need code for that. Right click your sheet tab, view code and paste the
code below in. If you type a legal filename into A2 the sheet is re-named.

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Cells.Count 1 Or IsEmpty(Target) Then Exit Sub
If Target.Address = "$A$2" Then
On Error Resume Next
ActiveSheet.Name = Target.Text
End If
End Sub

Mike

"Christine" wrote:

Hello, I've looked for a post on this and in Excel help but drawing a blank.
Hoping one of you might have an answer for me.

Is there a formula that will insert the value on spreadsheet tab into a
cell€¦.or vice versa - the value in a cell into the tab?

For instance, I would like to put a name in cell A2 and have the tab for
that worksheet be the same as whatever the value in A2 is.

Hope that makes sense.

Regards,

Christine

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 147
Default Naming of tabs from data in a worksheet

You folks on this site are so smart....and so helpful!!! Thank you very much.

Christine

"Mike H" wrote:

Hi,

You need code for that. Right click your sheet tab, view code and paste the
code below in. If you type a legal filename into A2 the sheet is re-named.

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Cells.Count 1 Or IsEmpty(Target) Then Exit Sub
If Target.Address = "$A$2" Then
On Error Resume Next
ActiveSheet.Name = Target.Text
End If
End Sub

Mike

"Christine" wrote:

Hello, I've looked for a post on this and in Excel help but drawing a blank.
Hoping one of you might have an answer for me.

Is there a formula that will insert the value on spreadsheet tab into a
cell€¦.or vice versa - the value in a cell into the tab?

For instance, I would like to put a name in cell A2 and have the tab for
that worksheet be the same as whatever the value in A2 is.

Hope that makes sense.

Regards,

Christine

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
naming tabs steve Excel Worksheet Functions 2 December 1st 07 08:15 PM
Naming Worksheet tabs Scott@CW Excel Discussion (Misc queries) 11 August 2nd 07 08:36 AM
Naming Tabs ebro Excel Discussion (Misc queries) 3 July 13th 06 11:07 PM
naming tabs Jeff Excel Worksheet Functions 8 February 6th 06 04:41 AM
How can I automate the naming of worksheet tabs? TJ Excel Discussion (Misc queries) 7 September 8th 05 12:01 AM


All times are GMT +1. The time now is 10:21 AM.

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"