Matador_24
Board Regular
- Joined
- Dec 1, 2011
- Messages
- 205
Hello,
I am starting to learn how to extract data from pivot tables. However, I have found some easy examples online but unfortunately I have a complex pivot table that constantly changes of number of rows and columns due to the month and year periods changing. Thus, I need to extract specific values from the pivot table using the first three columns (fields), I will send this specific values to another sheet. I can not use vlookup because the number of columns change constantly. Thus, I would like to use VBA to extract the below values from the pivot table, I am asking three different values so that I can see how to use the different fields considering different months, years and total/grand total combinations so that I can see the difference among them.
Could you please help me out with the code to extract the amount values in:
Blue:
I want to be able to extract and SAVE into a variable $ 1,666.58 from the table; thus, using 10003 (Account number field) and considering grand total as column.
Green:
I want to be able to extract and save $ 609,859.36 from the table; thus using 20000 - Liabilities Total (Account GL field) and considering 2016 total as column.
Red
I want to be able to extract $ 626.54 from the table by using Expenses Operating (Account name field) and considering the period month 3 of year 2016.
Thanks for your help in advance! here is the table:
<tbody>
</tbody>
I am starting to learn how to extract data from pivot tables. However, I have found some easy examples online but unfortunately I have a complex pivot table that constantly changes of number of rows and columns due to the month and year periods changing. Thus, I need to extract specific values from the pivot table using the first three columns (fields), I will send this specific values to another sheet. I can not use vlookup because the number of columns change constantly. Thus, I would like to use VBA to extract the below values from the pivot table, I am asking three different values so that I can see how to use the different fields considering different months, years and total/grand total combinations so that I can see the difference among them.
Could you please help me out with the code to extract the amount values in:
Blue:
I want to be able to extract and SAVE into a variable $ 1,666.58 from the table; thus, using 10003 (Account number field) and considering grand total as column.
Green:
I want to be able to extract and save $ 609,859.36 from the table; thus using 20000 - Liabilities Total (Account GL field) and considering 2016 total as column.
Red
I want to be able to extract $ 626.54 from the table by using Expenses Operating (Account name field) and considering the period month 3 of year 2016.
Thanks for your help in advance! here is the table:
<tbody> </tbody> |
<tbody>
</tbody>