+ Reply to Thread
Results 1 to 6 of 6

Runtime error 1004: Insert method of Range class failed......not sure why

  1. #1
    Forum Contributor
    Join Date
    12-01-2007
    Location
    USA-North Carolina
    MS-Off Ver
    MS Office 2016
    Posts
    2,601

    Runtime error 1004: Insert method of Range class failed......not sure why

    I have this code which reads in an input file...........today i recieved a new input file. I get a runtime error in the following procedure and i am not sure why. The actual debugger highlights the following line of code.

    Please Login or Register  to view this content.

    the procedure which contains the error is shown below.



    Please Login or Register  to view this content.

  2. #2
    Administrator JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Runtime error 1004: Insert method of Range class failed......not sure why

    Maybe take out the second .Resize command, seems redundant.
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  3. #3
    Forum Contributor
    Join Date
    12-01-2007
    Location
    USA-North Carolina
    MS-Off Ver
    MS Office 2016
    Posts
    2,601

    Re: Runtime error 1004: Insert method of Range class failed......not sure why

    but it has run like this using both resize commands for some time.........i wish i could post this "new" input file but i cant...........

  4. #4
    Administrator JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Runtime error 1004: Insert method of Range class failed......not sure why

    When you DEBUG at the moment of error, and it highlights that line of code, what are the current values of all the variables in that code? Hover your mouse over them or use the Watch Window to get those.

  5. #5
    Forum Contributor
    Join Date
    12-01-2007
    Location
    USA-North Carolina
    MS-Off Ver
    MS Office 2016
    Posts
    2,601

    Re: Runtime error 1004: Insert method of Range class failed......not sure why

    the only variable that shows any value is

    last_row_in_study_col


    and its value is showing as 4384

  6. #6
    Administrator JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Runtime error 1004: Insert method of Range class failed......not sure why

    Maybe:
    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