Solved

how to deal with getpivotdata returing #ref!

Posted on 2011-03-25
4
332 Views
Last Modified: 2012-06-22
I have a pivot that shows data over time and includes historical data. A table that references that pivot shows the data for each month in the year, so, when the current year is selected, some cell have a #ref! because that month hasn't occurred yet and there's no data in the pivot, or, historically we don't have all the data for a previous year.

We need to be compatible with 2003, so, iserror is out and we also need to chart and do formulas based on the table (that get it's data from the pivot).

I also would like it so that if I sum 3 months (for a quarter) that all have no data, the result would be blank and not 0.

I did try =if(isref(getpivotdata(xxx), getpivotdata(xxx),"")
but, summing 3 cells like that, that are "", returns 0 and I'd rather have the result be blank, and, that formula seems rather long.

thanks
alan
0
Comment
Question by:avoorheis
  • 2
4 Comments
 
LVL 1

Expert Comment

by:TonyWong
ID: 35216718
Depending on what version of Excel you're using, you can go into the OPtions and Advanced then uncheck 'Show zero in cells that have a zero value' (Excel 2010).

As for the other part  in your question, hope someone else can give you a solution.

Cheers,
Tony
0
 

Author Comment

by:avoorheis
ID: 35216726
using excel 2007, but, must be compatible with 2003
0
 
LVL 32

Accepted Solution

by:
Rob Henson earned 300 total points
ID: 35216797
You can use iserror in 2003 so this would work:

IF(ISERROR(GETPIVOTDATA(###)),0,GETPIVOTDATA(###))

Cheers
Rob H
0
 
LVL 1

Assisted Solution

by:TonyWong
TonyWong earned 200 total points
ID: 35216835
here's a wee link:

http://office.microsoft.com/en-us/excel-help/hide-error-values-and-error-indicators-in-cells-HP003056121.aspx#BMformat_text_in_cells_that_contain_err

It's for Excel 2003 so you should be able to do any of the methods listed in this article.

Cheers,
Tony
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Improved? Move/Copy Add-in Replacement - How to avoid the annoying, “A formula or sheet you want to move or copy contains the name XXX, which already exists on the destination worksheet.” David Miller (dlmille)  It was one of those days… I wa…
This article will guide you to convert a grid from a picture into Excel format using Microsoft OneNote and no other 3rd party application.
The viewer will learn how to create two correlated normally distributed random variables in Excel, use a normal distribution to simulate the return on different levels of investment in each of the two funds over a period of ten years, and, create a …
This Micro Tutorial will demonstrate the scrolling table in Microsoft Excel using the INDEX function.

929 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now