+ Reply to Thread
Results 1 to 5 of 5

Find & Replace on Workbook Open - Error Method 'Cells' of object'_Global' failed

  1. #1
    Registered User
    Join Date
    04-18-2013
    Location
    Sweden
    MS-Off Ver
    Excel 2010
    Posts
    37

    Find & Replace on Workbook Open - Error Method 'Cells' of object'_Global' failed

    Hi,

    I recorded a macro to be used on Workbook Open which finds and replaces blank looking cells to truly make them blank. However, I keep getting the following error:

    Run-time error '1004':
    Method 'Cells' of object '_Global' failed

    Does anyone know what the issue is with my code & what a possible solution might be?

    Please Login or Register  to view this content.
    Thanks for any help on this!

  2. #2
    Forum Expert Vikas_Gautam's Avatar
    Join Date
    06-04-2013
    Location
    Ludhiana,Punjab, India
    MS-Off Ver
    Excel 2013
    Posts
    1,850

    Re: Find & Replace on Workbook Open - Error Method 'Cells' of object'_Global' failed

    You should have provided the workbook to test. You also didn't said anything about on which line had the error appeared.
    However try the following code:-

    Please Login or Register  to view this content.
    Regards,
    Vikas Gautam
    Excel-buzz.blogspot.com

    Excel is not a matter of Experience, its a matter of Application.

    Say Thanks, Click * Add Reputation

  3. #3
    Registered User
    Join Date
    04-18-2013
    Location
    Sweden
    MS-Off Ver
    Excel 2010
    Posts
    37

    Re: Find & Replace on Workbook Open - Error Method 'Cells' of object'_Global' failed

    Thanks for the response.

    Just FYI, In my initial code, I was receiving an error on these lines of text:

    Please Login or Register  to view this content.
    I've tried using your code, and am unfortunately still receiving the same error on this line:

    FndRng.Select

  4. #4
    Forum Expert Vikas_Gautam's Avatar
    Join Date
    06-04-2013
    Location
    Ludhiana,Punjab, India
    MS-Off Ver
    Excel 2013
    Posts
    1,850

    Re: Find & Replace on Workbook Open - Error Method 'Cells' of object'_Global' failed

    Okay then..
    Attach a sample workbook. Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic

  5. #5
    Registered User
    Join Date
    04-18-2013
    Location
    Sweden
    MS-Off Ver
    Excel 2010
    Posts
    37

    Re: Find & Replace on Workbook Open - Error Method 'Cells' of object'_Global' failed

    After I made the file into a sample workbook I realized that this error is only occurring on my actual file, which is located on a Sharepoint Team Site. The second I move the file locally, the error magically goes away...

    For what it's worth, I've attached the sample file. It works perfectly fine, so making a before/after page won't really help since the code will fix the "before" worksheet anyway.

    The main problem is now that my code for some reason is not working on the actual file on the internet. Maybe this topic doesn't belong in this thread since it's a different problem than I first thought


    Samplebook_2.xlsm

+ 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. Method 'Cells' of object'_Global' failed - Error on Workbook Open()
    By goomblar in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-12-2015, 04:34 AM
  2. [SOLVED] Method 'Range' of Object'_Global' Failed Error
    By cmurda in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-13-2014, 07:11 PM
  3. VBA Method 'Range' of object '_Global' failed error
    By JKCincy in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 12-21-2009, 07:46 PM
  4. Run time Error '1004: Method 'Cells' of object'_Global' failed
    By Ajay_N in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-11-2006, 11:57 PM
  5. [SOLVED] Run-time error '1004': Method 'Cells' of object _Global failed
    By Fran D in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-12-2006, 11:50 AM

Tags for this Thread

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