[Previous] [Contents] [Next]

Eliminate Blank Cells in the Data Area


People started complaining about the blank cells immediately when pivot tables were first introduced. Anyone using Excel 97 or later can easily replace blank cells with zeroes. In the user interface, the setting can be found in the PivotTable Options dialog box. Choose the For Empty Cells, Show option and type 0 in the box.

The equivalent operation in VBA is to set the NullString property for the pivot table to "0".

NOTE

Although the proper code is to set this value to a text zero, Excel actually puts a real zero in the empty cells.



[Previous] [Contents] [Next]