+ Reply to Thread
Results 1 to 3 of 3

Runtime 57121 - Wierd Problem Selecting Sheets

  1. #1
    Registered User
    Join Date
    04-28-2004
    Posts
    49

    Runtime 57121 - Wierd Problem Selecting Sheets

    I am having a wierd problem with Excel 2007. I have this spreadsheet that uses VBA forms to manipulate data entry and create reports. At first the program ran fine on my local pc. At then put it on sharepoint and for the most part it also ran fine. Now I copied a local version back to my desktop and I get the 57121 runtime error. It is strange because I know how to avoid it but I don't quite understand why.

    When I first open the excel file and run the program I get the error when it tries to select a sheet in the vba code. When I click on debug I get this image in VBA Editor

    \1

    If you notice in the explorer view pane, the sheets are in blue and do not show the "name of the sheet". If I close the excel file, reopen it, go into the VBA editor before I execute the code that changes the sheet I get this in the explorer view pane:

    \1

    Which is normal. If i close out the vba editor and execute the code now, it runs fine. This happens each and every time I do this. I also tried the wait statement, but that did not work, any ideas?

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Runtime 57121 - Wierd Problem Selecting Sheets

    Attach the workbook
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  3. #3
    Registered User
    Join Date
    04-28-2004
    Posts
    49

    Re: Runtime 57121 - Wierd Problem Selecting Sheets

    Its proprietary information I would rather not expose, can you tell me what the sheets in blue in my first screenshot mean...

+ 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