error 1004

  1. R

    Error 1004

    Hi All Im creating a macro which inserts formulas and then autofill the column to last the last row. All formulas works except this one: Range("J2").Select ActiveCell.FormulaR1C1 = _...
  2. I

    VBA Code issues - Cannot get file to save as using cell contents

    Hi guys, I'm pretty new to VBA. I know there are some similar threads on here which have similar issues, I've worked my way through them and I'm still at a loss as to why my code won't work. I'm trying to create a button which will save the workbook to a certain location using the contents of...
  3. S

    Creating a Pivot Table with VBA

    Hey guys, I am trying to create a pivot table with VBA based off of some data that I have. Here is my code: Option Explicit Dim dolSht As Worksheet, hourSht As Worksheet Dim sumSht As Worksheet, byCustSht As Worksheet, allCostSht As Worksheet Dim ptCache As PivotCache Dim pt As PivotTable...
  4. L

    erro de definição de aplicativo ou de definição de objeto

    Olá, fiz uma parte do codigo em uma planilha separada pois a que é a planilha final está muito pesada com codigos. Na planilha separada o codigo roda perfeitamente, porém quando copio e colo na planilha final ela da um erro: "erro de definição de aplicativo ou de definição de objeto - 1004"...
  5. H

    error 1004 while saving worksheet

    Dear All, Using VBA code as given below, I get an error message (error 1004, Method SaveAs of object_Workbook failed) while saving the second worksheet (marked with *** behind the code line). It seems it has to do with saving twice in a row from the same Workbook. At least that is what I have...
  6. E

    macro to copy data on a loop until a blank row is hit errors

    I am trying to write a macro with VBA that will copy the data from my table in a sheet tiled "Front End" to a table on another sheet called "Raw Data". here is my code so far for the copying and pasting into the other sheet in the next empty row. I keep getting error that says "application...
  7. R

    Help with "Save to PDF" Error...Please Help...

    I had this code working with no problem, now it's giving me an error '1004' Document not Saved. Document may be open, or an error may have occured when saving. Don't know where I went wrong...any help is appreciated. Sub savetopdf()' ' savetopdf Macro ' Dim saveFileName As String Dim...
  8. E

    Excel VBA unable to get the AverageIf, Run-time error 1004

    Hi! Please help me to solve a problem. I have Excel’s reports created by some analytic software. There are many data there. One of my actions is to apply AverageIf function for two columns (average from L column based on G column criteria). Moreover L column numbers originally go as a text...
  9. I

    Disabling ScreenUpdating cause copy-paste to throw 1004 error.

    Little background to my question. (Office 2010, if it helps) I'm working on the project which should do pretty simple thing - take data from two sources and make printable pages (mean align data on the page properly, so it looks nice when printed). The problem is - both sets of data should be...
  10. M

    Error "1004 a table cannot overlap another table"

    Hello everyone. I just recorded a Macro that copies a table from a spreadsheet and pastes it on another cell. It turned out that it gives the error "1004 a table cannot overlap another table". I figured out that it is happening because the table name is fixed to a String that does not vary by...
  11. D

    Misterious Error when copying and pasting from a second workbook

    Hi Gurus, I have been facing a problem that I am unable to solve by myself. I am copying and pasting a few worksheets from a SharePoint site into a local file. Some of the worksheets are lists so I have to differentiate among them. Nonetheless Excel will not allow me to paste in the local...
  12. J

    Posting into next empty column

    I AM STRUGGLING WITH GETTING THIS PIECE OF CODE TO WORK. i KEEP GETTING "APPLICATION DEFINED ERROR AND OBJECT DEFINED ERROR" AND CANT SEEM TO FIGURE OUT WHY. IT ALL LOOKS CORRECT TO ME. PLEASE HELP ME OUT Dim source As Worksheet Dim destination As Worksheet Dim emptyColumn As...
  13. A

    Chart SeriesCollection error when selecting X ranges in a loop

    Hi everybody, I met a problem when creating multiple series in one chart using a macro. All the series have the same range for X axis but different range for Y axis. The number of series is a variable, and I tried to define the X and Y axis ranges for each series respectively using a loop...
  14. P

    Run-time Error 1004: PasteSpecial Method of Range Class Failed

    Group, I've written a macro to copy a part of a row from one workbook into another. This macro has run for many hours without fail (it's moved data from 14,400 workbooks so far). Unfortunately it is stopping on one specific workbook and I can't figure out why. Here's the code I've written...
  15. P

    Creating a PivotTable with VBA returning Run-Time error 1004

    As the title says, when I try and create a PivotTable using a VBA function (I'm using the first method on this page), it returns the following error: "Run-time error '1004': Application-defined or object-defined error" According to Microsoft's page about the error that it is a catch-all for...
  16. H

    Error 1004 unable to get workclassfunction networkdays

    Hello, In below standing code, I got stuck on a 1004 error that tells me: "unable to get worksheetfunction class networkdays". Marked in red. However, one line before this function has also been used to calculate the difference between two dates. Does someone have a suggestion how to resolve...
  17. L

    “Unable to get the VLookup property of the WorksheetFunction Class” error

    Hi all, I am trying to set the values in column B in my Workbook "Copy of Dash Board Shell" (shown in the image below) equal to the value derived from my HLOOKUP function from my data workbook shown as second image below Copy of Dash Board Shell Data file so esentially the code will find a...
  18. W

    VBA Error Handling Tips?

    I am actually fairly new to VBA coding and is at the point where I am trying to learn how to debug a current program given to me by a coworker that I wish to understand and possibly improve to suit my needs. Public Sub Patient_Records() Dim FF As Long, strText As String, strFile As...
  19. M

    EntireRow.Delete not working

    Hi. I need to delete rows from a ListObject very fast, based on criteria applied on a date column. I get the 1004 Delete method of Range class failed error on the EntireRow.Delete line: Sub DeleteOldPhoneCalls(ByRef tblCalls As ListObject) Dim rngDelete As Range...
  20. J

    Open multiple macros with one macro even when one gives error

    Dear all, I am having difficulties with an, what i think, easy macro. I made multiple macro's to change the filter(date) of a pivot. All these pivots are based on different databases. Sometimes when i fill in a date that the pivots need to filter on, it gives me an 1004 error. This is due to...

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