If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Error 1004
I am attempting to make a dynamic Histogram and chart. I have recorded the
macro but when I run it the macro breaks and gives me the above error saying ATPVBAEN.XLA cant be found. I have tried it with the empty sheet there and with no extra tab. Thank you for your help. Tim Peter |
#2
|
|||
|
|||
Error 1004
Have you installed the Analysis ToolPak? This is included within
XL2007, but on earlier versions you need to install it - check XL Help on how to do this. Hope this helps. Pete On Nov 11, 4:29*pm, tpeter wrote: I am attempting to make a dynamic Histogram and chart. I have recorded the macro but when I run it the macro breaks and gives me the above error saying ATPVBAEN.XLA cant be found. I have tried it with the empty sheet there and with no extra tab. Thank you for your help. Tim Peter |
#3
|
|||
|
|||
Error 1004
Post the code or at least the line it breaks on
"tpeter" wrote: I am attempting to make a dynamic Histogram and chart. I have recorded the macro but when I run it the macro breaks and gives me the above error saying ATPVBAEN.XLA cant be found. I have tried it with the empty sheet there and with no extra tab. Thank you for your help. Tim Peter |
#4
|
|||
|
|||
Error 1004
'Check out the below link
http://support.microsoft.com/default.aspx/kb/192642 Make sure you have loaded Analysis ToolPak - VBA. from ToolsAdd-Ins In case you are using 2007 (http://office.microsoft.com/en-us/ex...215691033.aspx) If this post helps click Yes --------------- Jacob Skaria "tpeter" wrote: I am attempting to make a dynamic Histogram and chart. I have recorded the macro but when I run it the macro breaks and gives me the above error saying ATPVBAEN.XLA cant be found. I have tried it with the empty sheet there and with no extra tab. Thank you for your help. Tim Peter |
#5
|
|||
|
|||
Error 1004
I am running 2003. The toolpack is installed, I recorded a macro and then
tried to get it to run as a check and then I got the initial error. Here is the code, it breaks as soon as it starts running: Sub His() ' ' His Macro ' Macro recorded 11/11/2009 by tpeter ' ' Application.Run "ATPVBAEN.XLA!Histogram", , "", , True, False, True, _ False ActiveWindow.SmallScroll Down:=-6 ActiveSheet.ChartObjects("Chart 1").Activate ActiveChart.ChartArea.Select ActiveSheet.Shapes("Chart 1").ScaleWidth 1.91, msoFalse, msoScaleFromTopLeft ActiveSheet.Shapes("Chart 1").ScaleHeight 3.3, msoFalse, msoScaleFromTopLeft ActiveChart.SeriesCollection(1).XValues = "=Sheet3!R2C1:R242C1" ActiveChart.SeriesCollection(1).Values = "=Sheet3!R2C2:R242C2" Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 230 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 229 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 228 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 226 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 221 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 216 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 212 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 207 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 201 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 186 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 177 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 167 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 159 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 140 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 133 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 124 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 118 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 112 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 101 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 96 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 92 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 89 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 84 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 82 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 78 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 75 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 70 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 67 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 65 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 62 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 54 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 50 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 45 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 41 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 31 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 25 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 16 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 5 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 1 ActiveChart.PlotArea.Select With Selection.Border .ColorIndex = 16 .Weight = xlThin .LineStyle = xlContinuous End With With Selection.Interior .ColorIndex = 2 .PatternColorIndex = 1 .Pattern = xlSolid End With ActiveChart.ChartArea.Select ActiveChart.HasLegend = False ActiveChart.Axes(xlValue).Select With ActiveChart.Axes(xlValue) .MinimumScaleIsAuto = True .MaximumScaleIsAuto = True .MinorUnitIsAuto = True .MajorUnitIsAuto = True .Crosses = xlAutomatic .ReversePlotOrder = False .ScaleType = xlLogarithmic .DisplayUnit = xlNone End With ActiveChart.ChartArea.Select ActiveSheet.Shapes("Chart 1").ScaleWidth 1.33, msoFalse, msoScaleFromTopLeft End Sub Thanks for all of your help. "Pete_UK" wrote: Have you installed the Analysis ToolPak? This is included within XL2007, but on earlier versions you need to install it - check XL Help on how to do this. Hope this helps. Pete On Nov 11, 4:29 pm, tpeter wrote: I am attempting to make a dynamic Histogram and chart. I have recorded the macro but when I run it the macro breaks and gives me the above error saying ATPVBAEN.XLA cant be found. I have tried it with the empty sheet there and with no extra tab. Thank you for your help. Tim Peter . |
#6
|
|||
|
|||
Error 1004
When I did this manually, I got ranges passed to the line of code:
Application.Run "ATPVBAEN.XLA!Histogram", ActiveSheet.Range("$C$16:$C$31"), _ ActiveSheet.Range("$M$16:$M$24"), ActiveSheet.Range("$D$16:$D$31"), True, _ False, False, False The parms are in this order: inprng outrng binrng pareto chartc chart labels I don't know what sheet you're using or the ranges that you need, but maybe you can plug your ranges (and other choices) into that line of code. tpeter wrote: I am running 2003. The toolpack is installed, I recorded a macro and then tried to get it to run as a check and then I got the initial error. Here is the code, it breaks as soon as it starts running: Sub His() ' ' His Macro ' Macro recorded 11/11/2009 by tpeter ' ' Application.Run "ATPVBAEN.XLA!Histogram", , "", , True, False, True, _ False ActiveWindow.SmallScroll Down:=-6 ActiveSheet.ChartObjects("Chart 1").Activate ActiveChart.ChartArea.Select ActiveSheet.Shapes("Chart 1").ScaleWidth 1.91, msoFalse, msoScaleFromTopLeft ActiveSheet.Shapes("Chart 1").ScaleHeight 3.3, msoFalse, msoScaleFromTopLeft ActiveChart.SeriesCollection(1).XValues = "=Sheet3!R2C1:R242C1" ActiveChart.SeriesCollection(1).Values = "=Sheet3!R2C2:R242C2" Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 230 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 229 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 228 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 226 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 221 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 216 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 212 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 207 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 201 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 186 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 177 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 167 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 159 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 140 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 133 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 124 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 118 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 112 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 101 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 96 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 92 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 89 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 84 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 82 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 78 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 75 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 70 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 67 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 65 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 62 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 54 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 50 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 45 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 41 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 31 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 25 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 16 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 5 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 1 ActiveChart.PlotArea.Select With Selection.Border .ColorIndex = 16 .Weight = xlThin .LineStyle = xlContinuous End With With Selection.Interior .ColorIndex = 2 .PatternColorIndex = 1 .Pattern = xlSolid End With ActiveChart.ChartArea.Select ActiveChart.HasLegend = False ActiveChart.Axes(xlValue).Select With ActiveChart.Axes(xlValue) .MinimumScaleIsAuto = True .MaximumScaleIsAuto = True .MinorUnitIsAuto = True .MajorUnitIsAuto = True .Crosses = xlAutomatic .ReversePlotOrder = False .ScaleType = xlLogarithmic .DisplayUnit = xlNone End With ActiveChart.ChartArea.Select ActiveSheet.Shapes("Chart 1").ScaleWidth 1.33, msoFalse, msoScaleFromTopLeft End Sub Thanks for all of your help. "Pete_UK" wrote: Have you installed the Analysis ToolPak? This is included within XL2007, but on earlier versions you need to install it - check XL Help on how to do this. Hope this helps. Pete On Nov 11, 4:29 pm, tpeter wrote: I am attempting to make a dynamic Histogram and chart. I have recorded the macro but when I run it the macro breaks and gives me the above error saying ATPVBAEN.XLA cant be found. I have tried it with the empty sheet there and with no extra tab. Thank you for your help. Tim Peter . -- Dave Peterson |
#7
|
|||
|
|||
Error 1004
Thanks Dave, I looked and the vba toolpack wasn't installed, now it works.
"Dave Peterson" wrote: When I did this manually, I got ranges passed to the line of code: Application.Run "ATPVBAEN.XLA!Histogram", ActiveSheet.Range("$C$16:$C$31"), _ ActiveSheet.Range("$M$16:$M$24"), ActiveSheet.Range("$D$16:$D$31"), True, _ False, False, False The parms are in this order: inprng outrng binrng pareto chartc chart labels I don't know what sheet you're using or the ranges that you need, but maybe you can plug your ranges (and other choices) into that line of code. tpeter wrote: I am running 2003. The toolpack is installed, I recorded a macro and then tried to get it to run as a check and then I got the initial error. Here is the code, it breaks as soon as it starts running: Sub His() ' ' His Macro ' Macro recorded 11/11/2009 by tpeter ' ' Application.Run "ATPVBAEN.XLA!Histogram", , "", , True, False, True, _ False ActiveWindow.SmallScroll Down:=-6 ActiveSheet.ChartObjects("Chart 1").Activate ActiveChart.ChartArea.Select ActiveSheet.Shapes("Chart 1").ScaleWidth 1.91, msoFalse, msoScaleFromTopLeft ActiveSheet.Shapes("Chart 1").ScaleHeight 3.3, msoFalse, msoScaleFromTopLeft ActiveChart.SeriesCollection(1).XValues = "=Sheet3!R2C1:R242C1" ActiveChart.SeriesCollection(1).Values = "=Sheet3!R2C2:R242C2" Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 230 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 229 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 228 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 226 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 221 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 216 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 212 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 207 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 201 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 186 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 177 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 167 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 159 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 140 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 133 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 124 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 118 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 112 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 101 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 96 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 92 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 89 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 84 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 82 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 78 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 75 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 70 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 67 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 65 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 62 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 54 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 50 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 45 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 41 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 31 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 25 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 16 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 5 Windows("Compiled w-0 425-630 n 800-1000.xls").ScrollRow = 1 ActiveChart.PlotArea.Select With Selection.Border .ColorIndex = 16 .Weight = xlThin .LineStyle = xlContinuous End With With Selection.Interior .ColorIndex = 2 .PatternColorIndex = 1 .Pattern = xlSolid End With ActiveChart.ChartArea.Select ActiveChart.HasLegend = False ActiveChart.Axes(xlValue).Select With ActiveChart.Axes(xlValue) .MinimumScaleIsAuto = True .MaximumScaleIsAuto = True .MinorUnitIsAuto = True .MajorUnitIsAuto = True .Crosses = xlAutomatic .ReversePlotOrder = False .ScaleType = xlLogarithmic .DisplayUnit = xlNone End With ActiveChart.ChartArea.Select ActiveSheet.Shapes("Chart 1").ScaleWidth 1.33, msoFalse, msoScaleFromTopLeft End Sub Thanks for all of your help. "Pete_UK" wrote: Have you installed the Analysis ToolPak? This is included within XL2007, but on earlier versions you need to install it - check XL Help on how to do this. Hope this helps. Pete On Nov 11, 4:29 pm, tpeter wrote: I am attempting to make a dynamic Histogram and chart. I have recorded the macro but when I run it the macro breaks and gives me the above error saying ATPVBAEN.XLA cant be found. I have tried it with the empty sheet there and with no extra tab. Thank you for your help. Tim Peter . -- Dave Peterson . |
Thread Tools | |
Display Modes | |
|
|