Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default refering to Pivot Tables

If cell A3 is part of a pivot table, is it possible to
reference the table without knowing the name or index?

If not, how do I obtain the name or index of a table if I
only know it's location on a sheet?

I can set the name for a table:
ActiveSheet.PivotTables("PivotTable2").Name
= "MyPivotTable"

But I don't know or have control over the existing name
(in this case, PivotTable2).

It appears that the default name of the table is a
sequential number based on the number of tables created in
the same Excel session.

Thanks in advance for any assistance.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,253
Default refering to Pivot Tables



?activecell.PivotTable (PT default property is name)
PivotTable1

?activecell.PivotTable.Tablerange2.Address
$A$3:$C$27

dim pt
set pt = Range("a3").pivottable



keepITcool

< email : keepitcool chello nl (with @ and .)
< homepage: http://members.chello.nl/keepitcool


"KT Doan" wrote:

If cell A3 is part of a pivot table, is it possible to
reference the table without knowing the name or index?

If not, how do I obtain the name or index of a table if I
only know it's location on a sheet?

I can set the name for a table:
ActiveSheet.PivotTables("PivotTable2").Name
= "MyPivotTable"

But I don't know or have control over the existing name
(in this case, PivotTable2).

It appears that the default name of the table is a
sequential number based on the number of tables created in
the same Excel session.

Thanks in advance for any assistance.


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Refering to multiple tables Broadband Al Excel Discussion (Misc queries) 2 July 3rd 08 10:07 PM
Building pivot tables in Excel 2007 based on existing pivot tables? [email protected] Excel Discussion (Misc queries) 4 December 26th 07 08:05 PM
OFFSET() not working within a SUMPRODUCT() when refering to a range in a pivot table Conan Kelly Excel Worksheet Functions 6 April 11th 07 12:32 AM
How does the term 'pivot' apply to Excel's Pivot tables and Pivot. stvermont Excel Discussion (Misc queries) 1 February 17th 05 01:34 AM
Pivot tables-controlling user interaction with pivot tables Sindhura Excel Programming 0 August 27th 03 02:10 PM


All times are GMT +1. The time now is 02:35 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"