USING IsNull Function in PivotTable

R

RussellT

Thanks in advance for the feedback!! I create Pivot Tables that use the
following code to create a calced field. The only problem is I get a table
that has tons of zeros in it. I can't use the universal turn of zeros on
worksheet because there are some zeros that don't result from a calced field
that should be displayed. I was wondering if anyone knew how or if I could
use the IsNull function so that resulting display would be a blank cell
instead of zero. When I replace ,0 in the formula with ,"" the entire calced
field disappears.

ActiveSheet.PivotTables("PivotTable2").CalculatedFields.Add _
"Weighted Avg Price", " If(PosSold > 0,rev / PosSold,0)"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top