+ Reply to Thread
Results 1 to 5 of 5

Intermittent Runtime error 1004 Paste Method of worksheet class failed

  1. #1
    Forum Contributor
    Join Date
    01-08-2017
    Location
    Salt Lake City, Ut.
    MS-Off Ver
    2019 and 365
    Posts
    135

    Question Intermittent Runtime error 1004 Paste Method of worksheet class failed

    I use the following code to copy a chart from one worksheet to another. The code works but fails intermittently on the line "ActiveSheet.Paste" . If I go into Debug, that line will show as hi-lighted in yellow. If I simply click on Run, then Continue or F5 it will proceed and paste the chart. Once in awhile that fails as well. It is very inconsistent, working perhaps ten times and then fails again.

    I have searched for solutions, but so far all have failed. I have tried pastespecial methods as well.
    Any help would be appreciated.

    Please Login or Register  to view this content.

  2. #2
    Forum Expert
    Join Date
    07-06-2004
    Location
    Northern California
    MS-Off Ver
    2K, 2003, 2010, O365
    Posts
    1,490

    Re: Intermittent Runtime error 1004 Paste Method of worksheet class failed

    Not a solution: when this happens next, try adding Err to the Watch window in the VBE Editor. What does it show?

  3. #3
    Forum Contributor
    Join Date
    01-08-2017
    Location
    Salt Lake City, Ut.
    MS-Off Ver
    2019 and 365
    Posts
    135

    Re: Intermittent Runtime error 1004 Paste Method of worksheet class failed

    It shows: Watch : + : Err : 1004 : Object/ErrObject : ChartData.CopyChart1

    PS, I renamed the chart from "Chart 1" to "Chart1", thinking that perhaps the space was causing a problem, but the error still occurs and is inconsistent.

  4. #4
    Forum Expert
    Join Date
    07-06-2004
    Location
    Northern California
    MS-Off Ver
    2K, 2003, 2010, O365
    Posts
    1,490

    Re: Intermittent Runtime error 1004 Paste Method of worksheet class failed

    I was hoping for something more useful, but that's Excel's fault there isn't.

    If this is intermittent, you could try putting the .Paste call inside a loop.

    Please Login or Register  to view this content.
    When Paste works, the chart image would presumably overlay ExpenseSummary!F6, so F6 should contain the text PROBLEM INCLUDING CHART.
    Last edited by hrlngrv; 10-17-2020 at 03:01 PM. Reason: generalization

  5. #5
    Forum Contributor
    Join Date
    01-08-2017
    Location
    Salt Lake City, Ut.
    MS-Off Ver
    2019 and 365
    Posts
    135

    Re: Intermittent Runtime error 1004 Paste Method of worksheet class failed

    Thank you hrlngrv, It works, but with a few modifications. This error has been haunting me for awhile. Thank again.

    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)

Similar Threads

  1. runtime error 1004 paste method of worksheet class failed
    By huongtram in forum Excel General
    Replies: 2
    Last Post: 06-25-2017, 04:53 AM
  2. runtime error 1004 paste method of worksheet class failed
    By Amittapre in forum Excel General
    Replies: 2
    Last Post: 03-08-2017, 05:27 AM
  3. [SOLVED] Runtime error 1004 paste method of worksheet class failed
    By Tapyr in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 03-16-2016, 12:02 PM
  4. runtime error 1004 - paste method of worksheet class failed
    By fmxwannabe in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-26-2014, 09:32 PM
  5. Replies: 1
    Last Post: 02-26-2014, 09:32 PM
  6. Help: Runtime Error 1004 Paste Method of Worksheet Class Failed
    By robertc93 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-11-2014, 10:50 AM
  7. runtime error 1004 paste method of worksheet class failed
    By wilsoj in forum Excel Programming / VBA / Macros
    Replies: 14
    Last Post: 01-26-2010, 05:58 PM

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