#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 190
Default pivot table

hi,

i have the following code:

e = sheets("sheet1").range("g3").value
msgbox e
with sheets("sheet1").pivottables("pivottable3").pivotf ields("FAC")
..pivotitems(e).visible = true
end with

but i am getting a runtime error 1004: unable to get the pivotitems property
ofthe pivotfield class.

i made sure that the value to be made visible is true. and even recorded a
macro with me checking the item to make it visible, to compare my code to
that. but i dont understand why this is not working.

in this case, the item to be made wisible is WBO

thanks in advance,
geebee



  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 130
Default pivot table

geebee,

Do you have quotation marks around the value in g3?



"geebee" wrote:

hi,

i have the following code:

e = sheets("sheet1").range("g3").value
msgbox e
with sheets("sheet1").pivottables("pivottable3").pivotf ields("FAC")
.pivotitems(e).visible = true
end with

but i am getting a runtime error 1004: unable to get the pivotitems property
ofthe pivotfield class.

i made sure that the value to be made visible is true. and even recorded a
macro with me checking the item to make it visible, to compare my code to
that. but i dont understand why this is not working.

in this case, the item to be made wisible is WBO

thanks in advance,
geebee



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 190
Default pivot table

hi,

no i do not. should i?

geebee


"JRForm" wrote:

geebee,

Do you have quotation marks around the value in g3?



"geebee" wrote:

hi,

i have the following code:

e = sheets("sheet1").range("g3").value
msgbox e
with sheets("sheet1").pivottables("pivottable3").pivotf ields("FAC")
.pivotitems(e).visible = true
end with

but i am getting a runtime error 1004: unable to get the pivotitems property
ofthe pivotfield class.

i made sure that the value to be made visible is true. and even recorded a
macro with me checking the item to make it visible, to compare my code to
that. but i dont understand why this is not working.

in this case, the item to be made wisible is WBO

thanks in advance,
geebee



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 130
Default pivot table

geebee,

No you should not. I tested your code and could only get the error when I
put quotes around data in cell g3. How is the value being populated in
g3-typing-pasting from somewhere else?

"geebee" wrote:

hi,

no i do not. should i?

geebee


"JRForm" wrote:

geebee,

Do you have quotation marks around the value in g3?



"geebee" wrote:

hi,

i have the following code:

e = sheets("sheet1").range("g3").value
msgbox e
with sheets("sheet1").pivottables("pivottable3").pivotf ields("FAC")
.pivotitems(e).visible = true
end with

but i am getting a runtime error 1004: unable to get the pivotitems property
ofthe pivotfield class.

i made sure that the value to be made visible is true. and even recorded a
macro with me checking the item to make it visible, to compare my code to
that. but i dont understand why this is not working.

in this case, the item to be made wisible is WBO

thanks in advance,
geebee



  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 190
Default pivot table

yes... the data is being pasted from somewhere else. it is a result of:
selection.pastespecial paste:=excelvalues, operation:=xlnone,
skipblanks:=true, transpose:=false

i am not sure what to do now...

geebee


"JRForm" wrote:

geebee,

No you should not. I tested your code and could only get the error when I
put quotes around data in cell g3. How is the value being populated in
g3-typing-pasting from somewhere else?

"geebee" wrote:

hi,

no i do not. should i?

geebee


"JRForm" wrote:

geebee,

Do you have quotation marks around the value in g3?



"geebee" wrote:

hi,

i have the following code:

e = sheets("sheet1").range("g3").value
msgbox e
with sheets("sheet1").pivottables("pivottable3").pivotf ields("FAC")
.pivotitems(e).visible = true
end with

but i am getting a runtime error 1004: unable to get the pivotitems property
ofthe pivotfield class.

i made sure that the value to be made visible is true. and even recorded a
macro with me checking the item to make it visible, to compare my code to
that. but i dont understand why this is not working.

in this case, the item to be made wisible is WBO

thanks in advance,
geebee





  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 130
Default pivot table

geebee,

Did you try typing the value and then running your code? Are you copying a
large amount of data or just the value for g3? If it is just the one value
then create a variable to hold the value and then

<to copy MyValue = Trim(ActiveCell)

<Paste Activecell=MyValue

"geebee" wrote:

yes... the data is being pasted from somewhere else. it is a result of:
selection.pastespecial paste:=excelvalues, operation:=xlnone,
skipblanks:=true, transpose:=false

i am not sure what to do now...

geebee


"JRForm" wrote:

geebee,

No you should not. I tested your code and could only get the error when I
put quotes around data in cell g3. How is the value being populated in
g3-typing-pasting from somewhere else?

"geebee" wrote:

hi,

no i do not. should i?

geebee


"JRForm" wrote:

geebee,

Do you have quotation marks around the value in g3?



"geebee" wrote:

hi,

i have the following code:

e = sheets("sheet1").range("g3").value
msgbox e
with sheets("sheet1").pivottables("pivottable3").pivotf ields("FAC")
.pivotitems(e).visible = true
end with

but i am getting a runtime error 1004: unable to get the pivotitems property
ofthe pivotfield class.

i made sure that the value to be made visible is true. and even recorded a
macro with me checking the item to make it visible, to compare my code to
that. but i dont understand why this is not working.

in this case, the item to be made wisible is WBO

thanks in advance,
geebee



  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 190
Default pivot table

hi,

its something wrong somewhere. i even changed the code to the following:
with activesheet.pivottables("pivottable3").pivotfields ("fac")
..pivotitems("SSS").visible = true

but i am still getting the same error message.

i am running out of idea on this one.



"JRForm" wrote:

geebee,

Did you try typing the value and then running your code? Are you copying a
large amount of data or just the value for g3? If it is just the one value
then create a variable to hold the value and then

<to copy MyValue = Trim(ActiveCell)

<Paste Activecell=MyValue

"geebee" wrote:

yes... the data is being pasted from somewhere else. it is a result of:
selection.pastespecial paste:=excelvalues, operation:=xlnone,
skipblanks:=true, transpose:=false

i am not sure what to do now...

geebee


"JRForm" wrote:

geebee,

No you should not. I tested your code and could only get the error when I
put quotes around data in cell g3. How is the value being populated in
g3-typing-pasting from somewhere else?

"geebee" wrote:

hi,

no i do not. should i?

geebee


"JRForm" wrote:

geebee,

Do you have quotation marks around the value in g3?



"geebee" wrote:

hi,

i have the following code:

e = sheets("sheet1").range("g3").value
msgbox e
with sheets("sheet1").pivottables("pivottable3").pivotf ields("FAC")
.pivotitems(e).visible = true
end with

but i am getting a runtime error 1004: unable to get the pivotitems property
ofthe pivotfield class.

i made sure that the value to be made visible is true. and even recorded a
macro with me checking the item to make it visible, to compare my code to
that. but i dont understand why this is not working.

in this case, the item to be made wisible is WBO

thanks in advance,
geebee



  #8   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 130
Default pivot table

geebee,

Can you post the code from your routine?

"geebee" wrote:

hi,

its something wrong somewhere. i even changed the code to the following:
with activesheet.pivottables("pivottable3").pivotfields ("fac")
.pivotitems("SSS").visible = true

but i am still getting the same error message.

i am running out of idea on this one.



"JRForm" wrote:

geebee,

Did you try typing the value and then running your code? Are you copying a
large amount of data or just the value for g3? If it is just the one value
then create a variable to hold the value and then

<to copy MyValue = Trim(ActiveCell)

<Paste Activecell=MyValue

"geebee" wrote:

yes... the data is being pasted from somewhere else. it is a result of:
selection.pastespecial paste:=excelvalues, operation:=xlnone,
skipblanks:=true, transpose:=false

i am not sure what to do now...

geebee


"JRForm" wrote:

geebee,

No you should not. I tested your code and could only get the error when I
put quotes around data in cell g3. How is the value being populated in
g3-typing-pasting from somewhere else?

"geebee" wrote:

hi,

no i do not. should i?

geebee


"JRForm" wrote:

geebee,

Do you have quotation marks around the value in g3?



"geebee" wrote:

hi,

i have the following code:

e = sheets("sheet1").range("g3").value
msgbox e
with sheets("sheet1").pivottables("pivottable3").pivotf ields("FAC")
.pivotitems(e).visible = true
end with

but i am getting a runtime error 1004: unable to get the pivotitems property
ofthe pivotfield class.

i made sure that the value to be made visible is true. and even recorded a
macro with me checking the item to make it visible, to compare my code to
that. but i dont understand why this is not working.

in this case, the item to be made wisible is WBO

thanks in advance,
geebee



  #9   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 190
Default pivot table

hi,

dos it even matter..especially if i cant even get the following to work:

sheets("sheet1").select
with activesheet.pivottables("pivottable3").pivotfields ("fac")
..pivotitems("SSS").visible = true
end with



"JRForm" wrote:

geebee,

Can you post the code from your routine?

"geebee" wrote:

hi,

its something wrong somewhere. i even changed the code to the following:
with activesheet.pivottables("pivottable3").pivotfields ("fac")
.pivotitems("SSS").visible = true

but i am still getting the same error message.

i am running out of idea on this one.



"JRForm" wrote:

geebee,

Did you try typing the value and then running your code? Are you copying a
large amount of data or just the value for g3? If it is just the one value
then create a variable to hold the value and then

<to copy MyValue = Trim(ActiveCell)

<Paste Activecell=MyValue

"geebee" wrote:

yes... the data is being pasted from somewhere else. it is a result of:
selection.pastespecial paste:=excelvalues, operation:=xlnone,
skipblanks:=true, transpose:=false

i am not sure what to do now...

geebee


"JRForm" wrote:

geebee,

No you should not. I tested your code and could only get the error when I
put quotes around data in cell g3. How is the value being populated in
g3-typing-pasting from somewhere else?

"geebee" wrote:

hi,

no i do not. should i?

geebee


"JRForm" wrote:

geebee,

Do you have quotation marks around the value in g3?



"geebee" wrote:

hi,

i have the following code:

e = sheets("sheet1").range("g3").value
msgbox e
with sheets("sheet1").pivottables("pivottable3").pivotf ields("FAC")
.pivotitems(e).visible = true
end with

but i am getting a runtime error 1004: unable to get the pivotitems property
ofthe pivotfield class.

i made sure that the value to be made visible is true. and even recorded a
macro with me checking the item to make it visible, to compare my code to
that. but i dont understand why this is not working.

in this case, the item to be made wisible is WBO

thanks in advance,
geebee



  #10   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 130
Default pivot table

geebee,

I think so. I can get the code below to work without any issues. But I am
typing in the data, changing the name of the pivottalble to pivottable3 and
it works.
However, it is up to you..


"geebee" wrote:

hi,

dos it even matter..especially if i cant even get the following to work:

sheets("sheet1").select
with activesheet.pivottables("pivottable3").pivotfields ("fac")
.pivotitems("SSS").visible = true
end with



"JRForm" wrote:

geebee,

Can you post the code from your routine?

"geebee" wrote:

hi,

its something wrong somewhere. i even changed the code to the following:
with activesheet.pivottables("pivottable3").pivotfields ("fac")
.pivotitems("SSS").visible = true

but i am still getting the same error message.

i am running out of idea on this one.



"JRForm" wrote:

geebee,

Did you try typing the value and then running your code? Are you copying a
large amount of data or just the value for g3? If it is just the one value
then create a variable to hold the value and then

<to copy MyValue = Trim(ActiveCell)

<Paste Activecell=MyValue

"geebee" wrote:

yes... the data is being pasted from somewhere else. it is a result of:
selection.pastespecial paste:=excelvalues, operation:=xlnone,
skipblanks:=true, transpose:=false

i am not sure what to do now...

geebee


"JRForm" wrote:

geebee,

No you should not. I tested your code and could only get the error when I
put quotes around data in cell g3. How is the value being populated in
g3-typing-pasting from somewhere else?

"geebee" wrote:

hi,

no i do not. should i?

geebee


"JRForm" wrote:

geebee,

Do you have quotation marks around the value in g3?



"geebee" wrote:

hi,

i have the following code:

e = sheets("sheet1").range("g3").value
msgbox e
with sheets("sheet1").pivottables("pivottable3").pivotf ields("FAC")
.pivotitems(e).visible = true
end with

but i am getting a runtime error 1004: unable to get the pivotitems property
ofthe pivotfield class.

i made sure that the value to be made visible is true. and even recorded a
macro with me checking the item to make it visible, to compare my code to
that. but i dont understand why this is not working.

in this case, the item to be made wisible is WBO

thanks in advance,
geebee



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
how to create pivot table from existing pivot table in excel 2007 Udayraj Dhulekar Excel Discussion (Misc queries) 2 July 8th 13 08:22 PM
Filter lines with Pivot table and non pivot table columns Grover Charts and Charting in Excel 4 September 28th 07 03:16 AM
Filter lines with Pivot table and non Pivot table columns Grover Excel Discussion (Misc queries) 1 September 26th 07 12:48 AM
Filter lines containing pivot table and non pivot table data Grover Excel Worksheet Functions 0 September 24th 07 07:20 PM
Help required with setting up a pivot table with the source on sheet1 to have the pivot table created on sheet called "report" Diana[_5_] Excel Programming 0 August 21st 03 10:19 PM


All times are GMT +1. The time now is 07:51 PM.

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

About Us

"It's about Microsoft Excel"