ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Pivot Table Error (https://www.excelbanter.com/excel-discussion-misc-queries/253442-pivot-table-error.html)

RussellT

Pivot Table Error
 
Thanks in advance.

I create PivotTables where one of the datafields is a Calced Field.
Sometimes the resulting calced field return #DIV/0! because of this the
resulting tables in the PivotTable display #DIV/0! also instead of the
totals. Any way around this problem?

Jim Thomlinson

Pivot Table Error
 
Fix your source data to remove the #DIV/0.

=if(A1 = 0, "", B1/A1)

divide by zero yeilds an indeterminate mathematical result. As such XL will
not use it in any calculations as the result of those calcualtions will also
be indeterminate...
--
HTH...

Jim Thomlinson


"RussellT" wrote:

Thanks in advance.

I create PivotTables where one of the datafields is a Calced Field.
Sometimes the resulting calced field return #DIV/0! because of this the
resulting tables in the PivotTable display #DIV/0! also instead of the
totals. Any way around this problem?


RussellT

Pivot Table Error
 
The error is a result of the following VBA code not a formula in a cell. any
suggestions?

ActiveSheet.PivotTables("PivotTable2").CalculatedF ields.Add "Weighted
Avg Price", _
"=rev / PosSold"
With ActiveSheet.PivotTables("PivotTable2").PivotFields ("Weighted
Avg Price")
.Orientation = xlDataField
.NumberFormat = "$#,##0"
End With


"Jim Thomlinson" wrote:

Fix your source data to remove the #DIV/0.

=if(A1 = 0, "", B1/A1)

divide by zero yeilds an indeterminate mathematical result. As such XL will
not use it in any calculations as the result of those calcualtions will also
be indeterminate...
--
HTH...

Jim Thomlinson


"RussellT" wrote:

Thanks in advance.

I create PivotTables where one of the datafields is a Calced Field.
Sometimes the resulting calced field return #DIV/0! because of this the
resulting tables in the PivotTable display #DIV/0! also instead of the
totals. Any way around this problem?



All times are GMT +1. The time now is 11:27 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com