
Usually, things go smoothly when you when you try to create a pivot table. Occasionally though, you might see a pivot table error message, with clear details, or a vague message.
Recently, when I opened an Excel file, one of those "unhelpful" error messages appeared -- "Reference isn't valid".

There was a chart on the worksheet, behind the message, and I (incorrectly) assumed that was the problem. However, the error turned out to be a pivot table problem - the source data table was broken!
I had to reformat the data as a named table, and that fixed things. See the details below, if you run into a similar problem.
In my workbook, a pivot table was causing the problem. The pivot table's source data was a table that no longer existed in the workbook. As soon as I fixed the table, the error message stopped appearing
To fix the problem I did these two things, and there are detailed steps below:
-- a) Located the pivot table's data source
-- b) Found and fixed the problem in the source data
To find the data source of a pivot table, follow these steps:
The Change PivotTable Data Source dialog box opens, and you can see the the source table or range in the Table/Range box. For my pivot table, it showed a table name - Table1
Usually, that table or range is highlighted in the background, but I could still see the pivot table in the background. So, I clicked the Cancel button, and went to the sheet where the data was stored.

When I checked the data sheet, there was no table - just a list on the worksheet. Nobody else uses the workbook, so how did the formatted Excel table go back to being just a list?
Table Removed During Repair
To fix the Reference isn't valid error, I formatted the list as an Excel table again.
Next, I checked the Change PivotTable Data Source dialog box again, and the table was correctly highlighted in the background.
I clicked Cancel, and the error message didn't appear again, when I refreshed the pivot table.

In the sample file that you can download below, I created an example that leads to a Reference Isn't Valid error.
However, now the named range is broken, so you'll see errors:

To check the named range, follow the steps below:

To fix the named range, follow the steps below
Now, the pivot table should refresh correctly, with no error messages.
Don't miss my monthly Excel newsletter! You'll get quick tips, article links, and a bit of fun. Add your email, and click Sign Up.
Next, when you get my reply, click the Confirm button. I add this step to protect you from spam!
Problem: Pivot Table Duplicate Items
Hide Error Values in Pivot Table
Last updated: November 13, 2024 12:48 PM