Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi all...
Is there a way (with vba) to find out if the active cell or active range is part of a Pivot Table, and if so retreiving the pivot table name? Regards Juan Sanchez |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Dim pt as PivotTable
for each pt in Activesheet.PivotTables if Not intersect(pt.TableRange2,activeCell) is Nothing then msgbox activeCell.Address & " is in " & pt.Name Exit for End if Next Change ActiveCell to selection, but that would only indicate if there is an overlap. If you want totally contained if Union(pt.TableRange2,Selection).Address = pt.TableRange2.Address then ' totally contained. -- Regards, Tom Ogilvy "Juan Sanchez" wrote in message ... Hi all... Is there a way (with vba) to find out if the active cell or active range is part of a Pivot Table, and if so retreiving the pivot table name? Regards Juan Sanchez |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Tom thanks for your reply... I appreciate it...
Regards Juan S |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
PIVOT TABLE's Custom Calculated Fields | Excel Discussion (Misc queries) | |||
how do I extend an existing pivot table's range | Excel Discussion (Misc queries) | |||
Can Multiple Range Pivot Table's field button's caption be changed | Excel Discussion (Misc queries) | |||
Accessing Pivot Table's Data in VBA | Excel Programming | |||
Accessing Pivot Table's Data | Excel Programming |