XL2000: Calculating Worksheet with Hidden Data Results in Zeroes

ID: Q235080


The information in this article applies to:


SYMPTOMS

When you publish a Microsoft Excel worksheet to an interactive Web page, if you recalculate the Microsoft Office Spreadsheet component and cells contain SUBTOTAL formulas, the result may be displayed as zero (0).


CAUSE

This problem occurs when all of the following conditions are true:


RESOLUTION

To resolve this issue, use either of the following methods.

Method 1: Unhide the Data Field Items in AutoFilter

To unhide the data field items, follow these steps:
  1. In the Office Spreadsheet object, click the arrow in the column that contains the AutoFilter data field.


  2. In the drop-down list, click to select (place a check mark in) any hidden data items. Click OK.


The totals and grand totals are displayed as expected.

Method 2: Use SUMIF and SUM Instead of SUBTOTAL

Instead of using the SUBTOTAL function, use the SUMIF and SUM functions as in the following example:
  1. In Excel, type the following into a worksheet:


  2. 
       A1 : Item            B1 : Amount
       A2 : A               B2 : 100
       A3 : A               B3 : 200
       A4 : B               B4 : 300
       A5 : B               B5 : 400
       A6 : A               B6 : 500
       A7 : B               B7 : 600
       A8 : Total A         B8 : =SUMIF($A$2:$A$7,"A",$B$2:$B$7)
       A9 : Total B         B9 : =SUMIF($A$2:$A$7,"B",$B$2:$B$7)
       A10: Grand Total     B10: =SUM($B$8:$B$9) 
  3. Select cells A2:B7.


  4. On the Data menu, point to Group and Outline and click Group.


  5. In the Group dialog box, click OK.


  6. On the Data menu, point to Group and Outline and click Hide Detail.


  7. Select cells A1:B10.


  8. On the File menu, click Save as Web Page.


  9. In the Save dialog box, click Selection:$A$1:$B$10 and click to select the Add interactivity check box.


  10. Click Publish.


  11. Check to select the Open published web page in browser check box. Click Publish.

    Your browser opens the Web page containing the Office Spreadsheet component.


  12. In your browser, select cell A1. Click the AutoFilter button on the Office Spreadsheet component toolbar.


If you recalculate the Office Spreadsheet component, the values should now display as expected.


STATUS

Microsoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article.


REFERENCES

For more information about the AutoFilter command, click Microsoft Excel Help on the Help menu, type "AutoFilter" in the Office Assistant or the Answer Wizard, and then click Search to view the topics returned.

For more information about subtotals, click Microsoft Excel Help on the Help menu, type "subtotals" in the Office Assistant or the Answer Wizard, and then click Search to view the topics returned.

For more information about the SUMIF function, click Microsoft Excel Help on the Help menu, type "SUMIF" in the Office Assistant or the Answer Wizard, and then click Search to view the topics returned.

Additional query words: XL2000


Keywords          : 
Version           : WINDOWS:2000
Platform          : WINDOWS 
Issue type        : kbbug 

Last Reviewed: July 14, 1999