Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 129
Default Edit a GETPIVOTDATA formula?

Hi,

I have a list of customers in Column B and I would like to copy the value in
B2 to replace the end of a formula in Column c

The formula in column c is

=(GETPIVOTDATA("Sum of Qty",'Y:\Spares sales\[2008.xls]2008
Table'!$A$5,"Customer Name","SUNDRY EXPORT USD"))

The last bit of the formula SUNDRY EXPORT USD needs to change to whatever is
in Column B for the same row.

It it possible?

Thanks
Winnie
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,355
Default Edit a GETPIVOTDATA formula?

You can replace "SUNDRY EXPORT USD" with B5 (or some other cell address.
--
HTH,
Barb Reinhardt

If this post was helpful to you, please click YES below.



"winnie123" wrote:

Hi,

I have a list of customers in Column B and I would like to copy the value in
B2 to replace the end of a formula in Column c

The formula in column c is

=(GETPIVOTDATA("Sum of Qty",'Y:\Spares sales\[2008.xls]2008
Table'!$A$5,"Customer Name","SUNDRY EXPORT USD"))

The last bit of the formula SUNDRY EXPORT USD needs to change to whatever is
in Column B for the same row.

It it possible?

Thanks
Winnie

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 129
Default Edit a GETPIVOTDATA formula?

Hi,

I tried that and all it does is add the cell reference to the formula not
the value of the cell reference.

I tried to create a macro which looks like this

Range("B2").Select
ActiveCell.FormulaR1C1 = "SUNDRY HOME"
Range("C2").Select
ActiveCell.FormulaR1C1 = _
"=(GETPIVOTDATA(""Sum of Qty"",'[2008.xls]2008
Table'!R5C1,""Customer Name"",""SUNDRY HOME""))"
Range("D2").Select

But I dont know how to make it work for the rest of Column B.

I am pulling the info from a pivot table and just wanted to save time by
copying and pasting the same formula but need a macro to change the last bit
in the formula ie The Customer name.

I hope I have made it a bit clearer on what i'm trying to achieve.

Thanks for your help.

"Barb Reinhardt" wrote:

You can replace "SUNDRY EXPORT USD" with B5 (or some other cell address.
--
HTH,
Barb Reinhardt

If this post was helpful to you, please click YES below.



"winnie123" wrote:

Hi,

I have a list of customers in Column B and I would like to copy the value in
B2 to replace the end of a formula in Column c

The formula in column c is

=(GETPIVOTDATA("Sum of Qty",'Y:\Spares sales\[2008.xls]2008
Table'!$A$5,"Customer Name","SUNDRY EXPORT USD"))

The last bit of the formula SUNDRY EXPORT USD needs to change to whatever is
in Column B for the same row.

It it possible?

Thanks
Winnie

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 239
Default Edit a GETPIVOTDATA formula?

On Oct 6, 10:03*am, winnie123
wrote:
Hi,

I tried that and all it does is add the cell reference to the formula not
the value of the cell reference.

I tried to create a macro which looks like this

Range("B2").Select
* * ActiveCell.FormulaR1C1 = "SUNDRY HOME"
* * Range("C2").Select
* * ActiveCell.FormulaR1C1 = _
* * * * "=(GETPIVOTDATA(""Sum of Qty"",'[2008.xls]2008
Table'!R5C1,""Customer Name"",""SUNDRY HOME""))"
* * Range("D2").Select

But I dont know how to make it work for the rest of Column B.

I am pulling the info from a pivot table and just wanted to save time by
copying and pasting the same formula but need a macro to change the last bit
in the formula ie The Customer name.

I hope I have made it a bit clearer on what i'm trying to achieve.

Thanks for your help.



"Barb Reinhardt" wrote:
You can replace "SUNDRY EXPORT USD" with B5 (or some other cell address..
--
HTH,
Barb Reinhardt


If this post was helpful to you, please click YES below.


"winnie123" wrote:


Hi,


I have a list of customers in Column B and I would like to copy the value in
B2 to replace the end of a formula in Column c


The formula in column c is


=(GETPIVOTDATA("Sum of Qty",'Y:\Spares sales\[2008.xls]2008
Table'!$A$5,"Customer Name","SUNDRY EXPORT USD"))


The last bit of the formula SUNDRY EXPORT USD needs to change to whatever is
in Column B for the same row.


It it possible?


Thanks
Winnie- Hide quoted text -


- Show quoted text -


Try INDIRECT for "SUNDRY EXPORT USD" part along with LEFT.

Regards,
Madiya
  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 129
Default Edit a GETPIVOTDATA formula?

Hi Madiya,

I am not sure where to put the Indirect and not sure what you mean by part
along with LEFT.

Sorry I am only just learning.

Thanks
Winnie

"Madiya" wrote:

On Oct 6, 10:03 am, winnie123
wrote:
Hi,

I tried that and all it does is add the cell reference to the formula not
the value of the cell reference.

I tried to create a macro which looks like this

Range("B2").Select
ActiveCell.FormulaR1C1 = "SUNDRY HOME"
Range("C2").Select
ActiveCell.FormulaR1C1 = _
"=(GETPIVOTDATA(""Sum of Qty"",'[2008.xls]2008
Table'!R5C1,""Customer Name"",""SUNDRY HOME""))"
Range("D2").Select

But I dont know how to make it work for the rest of Column B.

I am pulling the info from a pivot table and just wanted to save time by
copying and pasting the same formula but need a macro to change the last bit
in the formula ie The Customer name.

I hope I have made it a bit clearer on what i'm trying to achieve.

Thanks for your help.



"Barb Reinhardt" wrote:
You can replace "SUNDRY EXPORT USD" with B5 (or some other cell address..
--
HTH,
Barb Reinhardt


If this post was helpful to you, please click YES below.


"winnie123" wrote:


Hi,


I have a list of customers in Column B and I would like to copy the value in
B2 to replace the end of a formula in Column c


The formula in column c is


=(GETPIVOTDATA("Sum of Qty",'Y:\Spares sales\[2008.xls]2008
Table'!$A$5,"Customer Name","SUNDRY EXPORT USD"))


The last bit of the formula SUNDRY EXPORT USD needs to change to whatever is
in Column B for the same row.


It it possible?


Thanks
Winnie- Hide quoted text -


- Show quoted text -


Try INDIRECT for "SUNDRY EXPORT USD" part along with LEFT.

Regards,
Madiya



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 239
Default Edit a GETPIVOTDATA formula?

On Oct 6, 12:57*pm, winnie123
wrote:
Hi Madiya,

I am not sure where to put the Indirect and not sure what you mean by part
along with LEFT.

Sorry I am only just learning.

Thanks
Winnie



"Madiya" wrote:
On Oct 6, 10:03 am, winnie123
wrote:
Hi,


I tried that and all it does is add the cell reference to the formula not
the value of the cell reference.


I tried to create a macro which looks like this


Range("B2").Select
* * ActiveCell.FormulaR1C1 = "SUNDRY HOME"
* * Range("C2").Select
* * ActiveCell.FormulaR1C1 = _
* * * * "=(GETPIVOTDATA(""Sum of Qty"",'[2008.xls]2008
Table'!R5C1,""Customer Name"",""SUNDRY HOME""))"
* * Range("D2").Select


But I dont know how to make it work for the rest of Column B.


I am pulling the info from a pivot table and just wanted to save time by
copying and pasting the same formula but need a macro to change the last bit
in the formula ie The Customer name.


I hope I have made it a bit clearer on what i'm trying to achieve.


Thanks for your help.


"Barb Reinhardt" wrote:
You can replace "SUNDRY EXPORT USD" with B5 (or some other cell address..
--
HTH,
Barb Reinhardt


If this post was helpful to you, please click YES below.


"winnie123" wrote:


Hi,


I have a list of customers in Column B and I would like to copy the value in
B2 to replace the end of a formula in Column c


The formula in column c is


=(GETPIVOTDATA("Sum of Qty",'Y:\Spares sales\[2008.xls]2008
Table'!$A$5,"Customer Name","SUNDRY EXPORT USD"))


The last bit of the formula SUNDRY EXPORT USD needs to change to whatever is
in Column B for the same row.


It it possible?


Thanks
Winnie- Hide quoted text -


- Show quoted text -


Try INDIRECT for "SUNDRY EXPORT USD" part along with LEFT.


Regards,
Madiya- Hide quoted text -


- Show quoted text -


You can use INDIRECT function to define a parameter in any formula.
In your case, if "SUNDRY EXPORT USD" is in say cell B5, then you can
use
indirect(B5) instead of "SUNDRY EXPORT USD".
If you want part of "SUNDRY EXPORT USD" say "SUNDRY EXPORT" only
then you can use =LEFT(B5,13) which will give you "SUNDRY EXPORT"

Hope this is usefull to you but I am not sure that it will work for
pivot tables
Since I am not an expert, you may like to refer to excel help for
exact syntext.

Regards.
Madiya
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
Can I edit a GETPIVOTDATA formula? winnie123 Excel Discussion (Misc queries) 4 October 6th 08 07:51 PM
Average from the GETPIVOTDATA formula Rob Excel Discussion (Misc queries) 1 May 15th 07 10:19 AM
Vlookup within GetPivotData formula Spidey Excel Worksheet Functions 2 November 29th 06 04:33 AM
Help a Newbie! Using GETPIVOTDATA formula! certain_death Excel Discussion (Misc queries) 1 August 9th 06 04:54 PM
GETPIVOTDATA FORMULA nazzoli Excel Worksheet Functions 0 November 22nd 05 09:41 PM


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

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

About Us

"It's about Microsoft Excel"