ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   How to pull values from the pivot table fields, through the code/. (https://www.excelbanter.com/excel-programming/358572-how-pull-values-pivot-table-fields-through-code.html)

seven_snow

How to pull values from the pivot table fields, through the code/.
 
I have a pivot table made from a set of data in the same workbook i m working
on.Now i want to get the values from pivot tables as and when i select
values, corresponding to that values i need only the sum fields value.
eg
field names:A B Sum
Values in filed A= 1,2,3
Values in filed B= 4,5,6
Values in field c= 5,7,9

so wenever i select (1 in A) & (4 in B) ,i should get the value of C(=5) in
some empty cell of Excel.
say somewhere in F7 value should come as 5

MattShoreson[_81_]

How to pull values from the pivot table fields, through the code/.
 

Have you thought about usign the formula GETPIVOTDATA or do you only
want to do it through code?


--
MattShoreson
------------------------------------------------------------------------
MattShoreson's Profile: http://www.excelforum.com/member.php...fo&userid=3472
View this thread: http://www.excelforum.com/showthread...hreadid=531831


seven_snow[_2_]

How to pull values from the pivot table fields, through the co
 
Yaa i tried that too, just for a temporary solution.but that wont work,
actually i have a huge data, so wanted to automate the process,thts why
wanted to do it through the code.
please tell me if there's a way out.

thanks

"MattShoreson" wrote:


Have you thought about usign the formula GETPIVOTDATA or do you only
want to do it through code?


--
MattShoreson
------------------------------------------------------------------------
MattShoreson's Profile: http://www.excelforum.com/member.php...fo&userid=3472
View this thread: http://www.excelforum.com/showthread...hreadid=531831



Tom Ogilvy

How to pull values from the pivot table fields, through the co
 
You example is pretty meaningless, so you would need to be more specific in
what you want. If you had a pivot table displayed as

1 4 5
2 5 7
3 6 9

then you could do

msgbox columns(1).Find(1).offset(0,2).Value

But that is obviously not what you want.

--
regards,
Tom Ogilvy


"seven_snow" wrote:

Yaa i tried that too, just for a temporary solution.but that wont work,
actually i have a huge data, so wanted to automate the process,thts why
wanted to do it through the code.
please tell me if there's a way out.

thanks

"MattShoreson" wrote:


Have you thought about usign the formula GETPIVOTDATA or do you only
want to do it through code?


--
MattShoreson
------------------------------------------------------------------------
MattShoreson's Profile: http://www.excelforum.com/member.php...fo&userid=3472
View this thread: http://www.excelforum.com/showthread...hreadid=531831




All times are GMT +1. The time now is 03:20 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com