+ Reply to Thread
Results 1 to 6 of 6

Naming sheets by using last filled in cell in column

  1. #1
    Registered User
    Join Date
    07-28-2014
    Location
    Velserbroek, Netherlands
    MS-Off Ver
    2010
    Posts
    14

    Naming sheets by using last filled in cell in column

    Hello,

    I am currently working on a spreadsheet with a lot of worksheets and I want these worksheets to be named by referring to the last filled in cell in the "C" column.

    Please Login or Register  to view this content.
    As you can see the formula is now using the the cell C2 as the name for the sheet, but that should be te last filled in sheets in column C. Thanks in advance.

    Regards,

    Marald

  2. #2
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: Naming sheets by using last filled in cell in column

    What is the use of the counter?

    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    07-28-2014
    Location
    Velserbroek, Netherlands
    MS-Off Ver
    2010
    Posts
    14

    Re: Naming sheets by using last filled in cell in column

    First off, thanks for your quick reply! I do not know what the counter is for, I did not create the code myself.

    I just have one more question regarding this code, I keep getting an error if the sheetname is already in use. How can I adjust the code so that no error occurs anymore.

  4. #4
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Naming sheets by using last filled in cell in column

    FWIW:

    Please Login or Register  to view this content.

  5. #5
    Forum Guru HaHoBe's Avatar
    Join Date
    02-19-2005
    Location
    Hamburg, Germany
    MS-Off Ver
    work: 2016 on Win10 (notebook), private: 2019 on Win10 (desktop), 2019 on Win11 (notebook)
    Posts
    8,198

    Re: Naming sheets by using last filled in cell in column

    Hi, John,

    your code will not consider that the sheet name might already being used and raise a RTE.

    @mlint:
    maybe try either of these code codes and see if they do what you want:
    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    Ciao,
    Holger
    Use Code-Tags for showing your code: [code] Your Code here [/code]
    Please mark your question Solved if there has been offered a solution that works fine for you

  6. #6
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: Naming sheets by using last filled in cell in column

    My code is wrong anyway. It returns the last row which is long, not the last value.
    Holger's code is right and use it.

+ 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. Macro to create new sheets and naming them after values in column in Sheet1
    By Tona in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 11-10-2014, 04:04 AM
  2. [SOLVED] Naming Same Cell on Different Sheets
    By Patish in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-27-2013, 01:09 PM
  3. Re-Naming Sheets per Cell data & Hiding Sheets
    By dej222 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-26-2009, 10:20 PM
  4. naming a column & naming a cell with a number
    By evanzo in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-29-2008, 10:49 PM
  5. [SOLVED] Naming sheets from a cell value
    By Tony4X4 in forum Excel General
    Replies: 3
    Last Post: 08-22-2005, 12:05 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