ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Naming a Tab (https://www.excelbanter.com/excel-programming/317534-naming-tab.html)

Phil12345678910

Naming a Tab
 
Hi,

Does anyone know if its possible to name a tab from a cell reference in a
worksheet.

I am developing a Excel spreadsheet to hold details of projects, each
project has a separate tab. I would like the tab to automatically rename
itself from the cell that the project number is typed into.....

Any help would be much appreciated.



Frank Kabel

Naming a Tab
 
Hi
in VBA with
with activesheet
..name=.range("A1").value
end with

"Phil12345678910" wrote:

Hi,

Does anyone know if its possible to name a tab from a cell reference in a
worksheet.

I am developing a Excel spreadsheet to hold details of projects, each
project has a separate tab. I would like the tab to automatically rename
itself from the cell that the project number is typed into.....

Any help would be much appreciated.



Husker87

Naming a Tab
 
I have the same question but just want to link one worksheet tab name
automatically to a cell in the worksheet. Change the cell and the tab name
on the worksheet changes€¦ can you help with the VBA code for that? Many
Thanks€¦.

"Frank Kabel" wrote:

Hi
in VBA with
with activesheet
.name=.range("A1").value
end with

"Phil12345678910" wrote:

Hi,

Does anyone know if its possible to name a tab from a cell reference in a
worksheet.

I am developing a Excel spreadsheet to hold details of projects, each
project has a separate tab. I would like the tab to automatically rename
itself from the cell that the project number is typed into.....

Any help would be much appreciated.



Bob Phillips[_6_]

Naming a Tab
 
Private Sub Worksheet_Change(ByVal Target As Range)

On Error GoTo ws_exit:
Application.EnableEvents = False
If Target.Address = "$H$1" Then
Me.Name = Target.Value
End If

ws_exit:
Application.EnableEvents = True
End Sub

'This is worksheet event code, which means that it needs to be
'placed in the appropriate worksheet code module, not a standard
'code module. To do this, right-click on the sheet tab, select
'the View Code option from the menu, and paste the code in.


--

HTH

RP
(remove nothere from the email address if mailing direct)


"Husker87" wrote in message
...
I have the same question but just want to link one worksheet tab name
automatically to a cell in the worksheet. Change the cell and the tab

name
on the worksheet changes. can you help with the VBA code for that? Many
Thanks..

"Frank Kabel" wrote:

Hi
in VBA with
with activesheet
.name=.range("A1").value
end with

"Phil12345678910" wrote:

Hi,

Does anyone know if its possible to name a tab from a cell reference

in a
worksheet.

I am developing a Excel spreadsheet to hold details of projects, each
project has a separate tab. I would like the tab to automatically

rename
itself from the cell that the project number is typed into.....

Any help would be much appreciated.






All times are GMT +1. The time now is 02:40 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com