+ Reply to Thread
Results 1 to 4 of 4

Creating Sheets From List

  1. #1
    Forum Contributor
    Join Date
    10-08-2010
    Location
    Texas
    MS-Off Ver
    Excel 2010
    Posts
    386

    Creating Sheets From List

    I know i have done this before, maybe i am just having a bad day. For some reason this is giving me an error. It will make a new sheet with the correct name, then a new sheet that is just "Sheet #" and then error out. what am i doing wrong?

    Please Login or Register  to view this content.
    Last edited by GaidenFocus; 11-18-2011 at 05:14 PM.

  2. #2
    Forum Expert tigeravatar's Avatar
    Join Date
    03-25-2011
    Location
    Colorado, USA
    MS-Off Ver
    Excel 2003 - 2013
    Posts
    5,361

    Re: Creating Sheets From List

    GaidenFocus,

    Give this a try:
    Please Login or Register  to view this content.
    Last edited by tigeravatar; 11-18-2011 at 03:28 PM.
    Hope that helps,
    ~tigeravatar

    Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble

  3. #3
    Forum Expert davegugg's Avatar
    Join Date
    12-18-2008
    Location
    WI, US
    MS-Off Ver
    2010
    Posts
    1,884

    Re: Creating Sheets From List

    When you create a new sheet, it becomes the activesheet. You need to keep a reference to the sheet you are on. A less confusing code may be:

    Please Login or Register  to view this content.
    Please note you will still get an error if you try to name a sheet the same name as an existing sheet, or if your cell has no value (because you can't name a sheet null).

    A bit more advanced would be this, which will warn you if one of those two conditions exist:

    Please Login or Register  to view this content.
    Is your code running too slowly?
    Does your workbook or database have a bunch of duplicate pieces of data?
    Have a look at this article to learn the best ways to set up your projects.
    It will save both time and effort in the long run!


    Dave

  4. #4
    Forum Contributor
    Join Date
    10-08-2010
    Location
    Texas
    MS-Off Ver
    Excel 2010
    Posts
    386

    Re: Creating Sheets From List

    ah yes, simple. forgot that the sheet was losing focus. thanks dave! im going to stick with this though

    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)

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