+ Reply to Thread
Results 1 to 4 of 4

Macro error when ran on multiple sheets on workbook (even though macro works)

  1. #1
    Registered User
    Join Date
    11-02-2012
    Location
    Dallas, TX
    MS-Off Ver
    Excel 2010
    Posts
    28

    Macro error when ran on multiple sheets on workbook (even though macro works)

    I have a macro that works like I want it to and runs through every sheet in the workbook. But when it finishes I get a pop-up error, even though it worked. Can someone tell me in my code what is wrong to remove the error.

    Please Login or Register  to view this content.
    I know the error has to be caused in this particular string of code:

    Please Login or Register  to view this content.
    Here is a picture of my error after clicking on debug:
    error.png

  2. #2
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,646

    Re: Macro error when ran on multiple sheets on workbook (even though macro works)

    Try this.
    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    11-02-2012
    Location
    Dallas, TX
    MS-Off Ver
    Excel 2010
    Posts
    28

    Re: Macro error when ran on multiple sheets on workbook (even though macro works)

    I tried to mimic what you did with the first part of my macro and could not get it to work. Your code work excellently...any suggestions on this one because I get the same error message as the one you fixed. I'm trying to do the same thing, go through each sheet on the workbook. What do I have that is wrong?


    Please Login or Register  to view this content.

  4. #4
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,646

    Re: Macro error when ran on multiple sheets on workbook (even though macro works)

    This might work, I say might because I'm not 100% sure what you are trying to do or the error you are getting.

    Anyway, here's the code.
    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