getpivotdata (offset)

btardo01

Board Regular
Joined
Oct 6, 2009
Messages
169
Office Version
  1. 2016
Platform
  1. Windows
I have the following formula that is returning the correct value:



cell 'ODS TTM Coverage'!N12 = GETPIVOTDATA("[Measures].[Amt]",'ODS TTM Coverage'!$A$5,"[Time].[Calendar]","[Time].[Calendar].[Year].&[2017].&[12]&","[Client].[Client.Name].&[M1 Tech]","[Coverage].[CoverageDescription]","[Coverage].[Coverage Description].&[Fee]")

I am currently using the formula :
=sum('ODS TTM Coverage'!N12:Offset('ODS TTM Coverage'!N12,0,-12)))

however, I would like to replace the reference to cell N12 with the Getpivotdata reference but Excel doesn't like that.

The reason I want to do this is because I need the sum (offset ) formula to be a bit more dynamic. I need to use 3 different criteria (time, client name and coverage) to find my starting point and then always sum 12 months prior. The range will also be dynamic so that's why I wanted to use the getpivotdata formula as opposed to needing to create and array formula..

thanks
 

Excel Facts

How to total the visible cells?
From the first blank cell below a filtered data set, press Alt+=. Instead of SUM, you will get SUBTOTAL(9,)

Forum statistics

Threads
1,223,248
Messages
6,171,027
Members
452,374
Latest member
keccles

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top