+ Reply to Thread
Results 1 to 5 of 5

Automatically Create & Name New Worksheet Based On Cell Value (date)

  1. #1
    Forum Contributor
    Join Date
    12-20-2011
    Location
    United States, Ohio
    MS-Off Ver
    Excel 2010
    Posts
    295

    Automatically Create & Name New Worksheet Based On Cell Value (date)

    I have this figuered out, KIND OF, and need some help.

    I am trying to create a new worksheet for every cell value.

    Please Login or Register  to view this content.
    But this code - kind of works.

    If you look at my attached file NewWorksheetTEST.xlsm , it works when the data is in 'January' format. But I need my data to be in 'mmm-yyyy' format (Jan-2012). Once I chnage the format, it doesnt work.

    I think its because January is text format and Jan-2012 is a date format, but I dont know how to update my code to accommodate the date format.

    Any suggestions would be greatly appreciated.

    Thanks in advance.
    Last edited by clemsoncooz; 12-30-2011 at 12:48 PM.

  2. #2
    Forum Expert
    Join Date
    12-15-2009
    Location
    Chicago, IL
    MS-Off Ver
    Microsoft Office 365
    Posts
    3,177

    Re: Automatically Create & Name New Worksheet Based On Cell Value (date)

    I revised your code a little bit

    Please Login or Register  to view this content.

  3. #3
    Forum Contributor
    Join Date
    12-20-2011
    Location
    United States, Ohio
    MS-Off Ver
    Excel 2010
    Posts
    295

    Re: Automatically Create & Name New Worksheet Based On Cell Value (date)

    Hello JieJenn. Thank you very much for taking the time to look at this and offer a solution. I appreciate that.

    But yours also "kind of" works - not quite what I am looking for.

    I'm looking for whatever the name is (and format) to show on the worksheet name. So if I type "1/1/12" into A1, but have the cell format to be "mmm-yyyy" (meaning Jan-2012 shows in A1), then the worksheet name would be Jan-2012. More so, if I typed 5/6/15, and the cell format shows to be May-2015, I want the worksheet name to be "May-2015."

    Does this make more sense?

    Thanks!

  4. #4
    Forum Contributor
    Join Date
    12-20-2011
    Location
    United States, Ohio
    MS-Off Ver
    Excel 2010
    Posts
    295

    Re: Automatically Create & Name New Worksheet Based On Cell Value (date)

    Maybe found the solution, If any one cares, I think this might be what I was after in the first place.
    Please Login or Register  to view this content.

  5. #5
    Forum Expert
    Join Date
    12-15-2009
    Location
    Chicago, IL
    MS-Off Ver
    Microsoft Office 365
    Posts
    3,177

    Re: Automatically Create & Name New Worksheet Based On Cell Value (date)

    The values in your workbook in Column A are "text" despite that the formatting was custom. Date formatting does not work with text, and that was where my assumption coming from.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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