Sheet Names

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Can I have the sheet tab be the same as a specified field in that sheet automatically
 
Hi
Put the following code in your worksheet module:
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Cells.Count > 1 Then Exit Sub
If Intersect(Target, Me.Range("A1")) Is Nothing Then Exit Sub
On Error GoTo CleanUp
application.enableevents = false
With Target
If .Value <> "" Then
Me.Name = .value
End If
End With
CleanUp:
Application.EnableEvents = True
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Excel Move or Copy Stopped Working? 0
Sheet tab names change automatically 3
Sheets Name 1
Excel Monthly Spread sheet. 12
Help to create a macro 2
dynamic worksheet name 1
Tab sheet name 3
Update workbook pages- how? 2

Back
Top