+ Reply to Thread
Results 1 to 2 of 2

Add a new sheet depending on cell value

  1. #1
    Registered User
    Join Date
    09-08-2017
    Location
    Quebec, Canada
    MS-Off Ver
    2013
    Posts
    4

    Add a new sheet depending on cell value

    Hi, I'm trying to write a code which would add a new sheet and name it, depending on the value of a cell.

    There would be a drop down list, then if an item is selected, a new sheet is created and named after the value of the cell.

    In my case, the cell is A2, and the choice is 1,2,3,4,5 and the corresponding sheet would be 1N,2N,3N,4N,5N. It works perfectly.

    My only problem is that I'd like it to erase the sheet and create another if the value is changed.

    For example:

    If i select 1, the sheet 1N is created, but if I change my choice to 2, the 1N sheet is deleted, and 2N is created.

    Here's an example sheet
    Attached Files Attached Files

  2. #2
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,525

    Re: Add a new sheet depending on cell value

    for the workbook provided.
    Please Login or Register  to view this content.

+ 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] How to repeat a cell depending on a value in another sheet
    By Barieq in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 10-26-2015, 09:18 AM
  2. [SOLVED] Activate Sheet depending on value in a cell
    By RinorM in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-30-2014, 07:00 AM
  3. Replies: 2
    Last Post: 04-27-2014, 06:39 PM
  4. Highlight Name on one sheet depending on cell value and name on another sheet
    By malcedge in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-19-2014, 09:36 PM
  5. [SOLVED] Copy cell from 1 sheet to another sheet depending on what info is displayed in a cell
    By chilli76 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 11-24-2013, 12:33 PM
  6. [SOLVED] Copying a specific Row from another sheet depending on a cell value
    By OAKLEY in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 09-19-2013, 03:52 AM
  7. Copy cell on sheet one to sheet 2 depending on another cell
    By madpammy in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-09-2013, 02:47 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