Hi All,

I've got a macro I wrote in Excel 2007 which updates a pivot table with a new range of information. It works nicely in 2007 using the following code (bearing in mind that I defined "Pivotrange" earlier in the macro).

Code:
ActiveWorkbook.Worksheets("Data Sheet").PivotTables("PivotTable1").ChangePivotCache ActiveWorkbook. _
        PivotCaches.Create(SourceType:=xlDatabase, SourceData:=pivotrange, Version:=xlPivotTableVersion10)
However, when my colleague tries to use it in Excel 2003 it return the error "Object doesn't support this property or method".

Is there an equivalent piece of code I could use that would update the existing pivottable to use the range "pivotrange" but which would be compatible with 2007 and 2003?

Many thanks.