1004 run-time error

  1. C

    Script crashes - sometimes

    I have a script I have been using for years, but at one point it started crashing on me, but only sometimes. Usually it is when I open it fresh. If I run a few of the other macros in the workbook to sort of "prime the pump," it works just fine. I am using Excel 2016 for Mac. I'm trying to copy a...
  2. U

    recorded macro throwing 1004 error

    Hi, So i'm kinda new to macros so i am recording them to have them done and to learn something. I have recorded a macro that puts a dropdown (this one is connected to the input of a cell in adjacent column). The macro looks like this: Sub Macro2() ' ' Macro2 Macro ' ' Range("AJ2").Select...
  3. E

    Item could not be found in the OLAP cube when using a variable

    Hi, I've got a workbook containing several pivot tables. I try to build a macro, so I can update outlook versions for all the tables at the same time. I have declared the outlook as a variable and inserted it into the code where the hard coded outlook used to be, but when I run the code, I get...
  4. G

    Array to range with values that look like formula

    Hello. I'm having a problem where excel will throw a 1004 error "application-defined or object-defined error". The issue is that I have an array of values with strings that look like "=?DAFqwr". As a minimal example of this: Sub testArr() dim arr(1 to 1, 1 to 1) as variant arr(1,1) =...
  5. B

    VBA Macro was working, now getting a 1004 error

    Hello, I have a macro that worked fine for a month and a half, but is now giving me a 1004 Runtime error "Application-defined or object defined error". Below is the code in which the macro is errors out on. The gist of the macro is to filter by a date provided by the user, then filter by a...
  6. V

    Why is this a run time error 1004?

    dashB.Range("A3").Resize(y - 1, 0).EntireRow.Clear Where y = 4 I have tried not using a substraction in the row identifier, but the error is the same.
  7. F

    VBA - 1004 Error #Ref

    Hello, I'm back again, let me just say that I found this website to be very helpful. I currently have a script that was created by an external source. I don't have access to that person anymore. When I try running the script its returning a 1004 error (see attachment). From what i can see...
  8. N

    1004 error on Array. Worksheet failed.

    First off thanks to everyone on this forum for your help. I have learned a ton and am able to create a process for my org that is going to save everyone a ton of hours. I will be excited to share with everyone once it is done. So the code below is supposed to reference a named range "_FileLoc"...
  9. E

    VBA Run-time error '1004'

    Hello everyone. I'm trying to finish the most complex macro I've ever done and have run into an error that is blowing my mind. I'm learning VBA so I would like to understand the error and not just get a fix, if that makes sense, so I don't make it again. I get an the '1004' error on my Boo...
  10. M

    GoTo Error Handling Not Working

    I am trying to copy a table from Excel and paste as an image to PowerPoint. For some reason, the copy/paste methods error out about 1 in 10 attempts to run the code. :confused: I added GoTo error handling but the code seems to be ignoring it. On the line...
  11. C

    Runtime error only when using keyboard command for macro

    Hi, I've made a spreadsheet that compiles data from 8 separate spreadsheets with 8 different passwords. It's the same group of people using all of them and it's a pain to type in 9 passwords - including the compilation one. The thing is, the macro works fine if you run it manually - View/Macros...
  12. W

    run-time error 1004 - Why?

    Hi one & all, I have used this site many a time and it has helped me a lot, but this is my first post so if I have posted it incorrectly, I'm sorry. I am also aware that there is probably a smarter way to do this code, but as I'm self taught it usually a matter of trial and error for me and I'm...
  13. C

    Rows - .EntireRow.Delete - 1004 Error, but rows ARE deleted

    I have a simple delete code line that gives me a 1004 error (Delete method of Range class failed), BUT the rows are deleted! The error causes the remaining code not to execute because of the error handling code I have which give a msgbox explaining that an error code occurred the exits. Any...
  14. F

    VBA - Copy/Paste with variable cell range - 1004 error

    I am getting a Run-time error '1004':Application-defined or object-defined error in copy/paste section of my code and I can't figure out why it is doing that. The last thing I tried was to add Cstr to the ranges. This macro is pulling information from one sheet and putting it to another, the...
  15. J

    Assistance with VBA Code Error

    Hi Guys, I have a large data source and I trying to create a macro which filters onto the necessary data then copy pastes that data onto separate sheets. From there, I am creating a pivot table off the copy pasted data onto the respective sheets. From month to month, there will be times where...
  16. C

    VBA Run-Time Error 1004

    I'm getting a "Run-Time Error 1004: Application-defined or object-defined" message during the debug process on this VLookup function. Error is happening on the VLookup, can't proceed further. I got the function to work on a previous section of code, and then adapted it for use in this new...
  17. L

    1004 runtime error when using row count in opened file

    Would someone please explain why I get the error. in Excel 2013 Run-time error '1004': Application-defined or object defined error Senario (Description followed by code) I have opened a workbook and worksheet (wsBS) from within the main worksheet (wsData). I want to find the last row of the...
  18. J

    Running-time error 1004-Invalid Parameter

    Please help me to debug this code. I have been reading this code over and over and can't see why error occurred. Thanks. Look at the red color line. Function createCharts() ' ***************************************************** Dim pivotSheet As Worksheet Dim lastRow As Long Dim...
  19. W

    1004 Run-time Error in Application.Caller when calling from another Control Form Object

    Hello all. I used the following line of code... Call Button_Differentials_ZeroOut ...to call another Button [Forms Control] and it blows up the Application.Caller in the "called" button with a "Run-time error '1004' - Unable to get the Buttons property of the Worksheet class. The specific line...
  20. S

    runtime error '1004': method 'range' of object '_global' failed

    Hi there, thanks for looking. I have a simple bit of code that I would like to loop through each column and then graph this. I have my dates in column A and then B, C, D..... etc are full of numbers. I would like them individually graphed into new sheets. I have written this code but for some...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top