+ Reply to Thread
Results 1 to 2 of 2

Change Sheet name based on Cell that contains a formuls

  1. #1
    Registered User
    Join Date
    09-12-2013
    Location
    Saint Paul, Minnesota, USA
    MS-Off Ver
    Excel 2010
    Posts
    1

    Change Sheet name based on Cell that contains a formuls

    Hi- I am using the following code to name my worksheets based on a cell on that same worksheet:

    Private Sub Worksheet_Change(ByVal Target As Range)
    If Target.Address(False, False) = "K4" Then Me.Name = Target.Value
    End Sub

    The issue is that the worksheet name only updates if i click into cell K4 to activate the cell. I think the issue is that K4 is not a hard coded value, but rather a formula. (The formula is a concatenation of a value from another cell on the sheet and a value from a drop down on summary sheet.)

    When I change the dropdown, then the value of K4 changes, but the worksheet name does not change. Is there a way to run the code based on a formula change instead of a manual change?

    Thanks for your insight.

  2. #2
    Forum Expert JasperD's Avatar
    Join Date
    05-07-2013
    Location
    Netherlands
    MS-Off Ver
    Excel 2016
    Posts
    1,393

    Re: Change Sheet name based on Cell that contains a formuls

    This will work. Make sure to dim the variable outside the sub.

    Please Login or Register  to view this content.
    Please click the * below if this helps
    Please click the * below if this helps

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Array lookup formuls, nesting in ifs, based off of a pivot slicer
    By jenncess in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 04-29-2013, 05:37 PM
  2. Array lookup formuls, nesting in ifs, based off of a pivot slicer
    By jenncess in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-29-2013, 05:36 PM
  3. Replies: 3
    Last Post: 12-16-2012, 12:49 PM
  4. VBA to change Sheet Name based on lookup from cell value.
    By jhall488 in forum Excel Programming / VBA / Macros
    Replies: 14
    Last Post: 10-30-2012, 05:21 PM
  5. How can I change sheet tab color based on cell value in sheet?
    By SCAScot in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-23-2005, 05:50 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1