run-time error ''5''

tintin1012000

Board Regular
Joined
Apr 27, 2011
Messages
231
Im trying to set up a macro to simply use data in a tab to created a pivot table
im getting a run-time error ''5'' and when i go to debug the below text is highlighted in yellow



any ideas ?

[ActiveWorkbook.PivotCaches.Create(SourceType:=xlDatabase, SourceData:= _
"Error rawdata!R1C1:R1704C14", Version:=xlPivotTableVersion10). _
CreatePivotTable TableDestination:="Error dashboard!R2C2", TableName:= _
"PivotTable4", DefaultVersion:=xlPivotTableVersion10'']
 

Some videos you may like

Excel Facts

Round to nearest half hour?
Use =MROUND(A2,"0:30") to round to nearest half hour. Use =CEILING(A2,"0:30") to round to next half hour.

steve the fish

Well-known Member
Joined
Oct 20, 2009
Messages
8,110
Office Version
  1. 365
Platform
  1. Windows
If sheet names have spaces in them they need to be enclosed by single quotes ' ........... '

Try that.
 

Watch MrExcel Video

Forum statistics

Threads
1,108,634
Messages
5,523,996
Members
409,555
Latest member
TIPSAREA

This Week's Hot Topics

Top