Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Extracting data from external pivot table - Office 2007
I have several Excel files, each of which are over 70MB xlsm files.
I need to get some data from the pivot tables in the above-mentioned files based on specified file and other criteria in pivot table. Does somebody know how to do this in VBA? I get error 1004 at set pt = line. I know the line below it is wrong. But that is a moot point, since i can't get to it. I tried the following code but it does not work. rangeAddr = "'" & filePath & "[" & FileName & "]" & sheetName & _ "'!A4" Set pt = Range(rangeAddr).PivotTable Worksheets("Sheet1").Range(Cells(i, j), Cells(i, j)).Value = _ pt.GetPivotData("Quantity", rangeAddr, "Transaction Type", _ Worksheets("Sheet1").Range(Cells(1, j), Cells(1, j)), "Chain Code", _ Worksheets("Sheet1").Range(Cells(2, j), Cells(2, j))).Value Thanks much. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Office 2007 Pivot Table shortcut keys | Excel Discussion (Misc queries) | |||
Office 2007 and Pivot Table Trouble | Excel Discussion (Misc queries) | |||
Display top ten items in an Office 2007 pivot table | Excel Discussion (Misc queries) | |||
View pivot table external data source in Excel 2007 | Excel Discussion (Misc queries) | |||
Extracting saved data from pivot table | Excel Discussion (Misc queries) |