PDA

View Full Version : Runtime error 13 : Excel vba pivot - please help



Amila Weeras
06-14-2016, 09:44 PM
Set rngData = wsData.Range("A1", "AC500000")
ActiveWorkbook.PivotCaches.Create(SourceType:=xlDatabase, SourceData:=rngData, Version:=xlPivotTableVersion12).CreatePivotTable TableDestination:=wsPvtTbl.Range("A1"), TableName:="PivotTable1", DefaultVersion:=xlPivotTableVersion12

Runtime error 13 : type missmatch

this script is working in my laptop but not working in my office PC.

please help.

mdmackillop
06-15-2016, 10:56 AM
Record a macro creating a simple pivot table and check versions. Change your code to use the older version on both machines.