WD: Incorrect Results in Formula Using ABOVE, BELOW, LEFT, RIGHT

ID: Q111886

The information in this article applies to:

SYMPTOMS

A formula field in a table yields an incorrect result when it includes ABOVE, BELOW, LEFT, or RIGHT if the defined range contains noncontiguous values (in other words, if there is one or more blank cell between two values).

For example, the formula in cell A4 of the following table shows a result of 4 instead of 7:

   |------------------|
   |               3  |
   |------------------|
   |                  |
   |------------------|
   |               4  |
   |------------------|
   |   {=SUM(ABOVE)}  |
   |------------------|

CAUSE

Word calculates correctly up to the first empty table cell, then stops. Word does not calculate any values beyond the first empty cell.

STATUS

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

WORKAROUNDS

To workaround this problem use one of the following methods.

Method 1: Type zero(0) in any blank cells

Type zero(0) in any blank cells included within the calculation range. For example:

   |------------------|
   |               3  | <(Cell A1)
   |------------------|
   |               0  | <(Cell A2)
   |------------------|
   |               4  | <(Cell A3)
   |------------------|
   |               0  | <(Cell A4)
   |------------------|
   |               5  | <(Cell A5)
   |------------------|
   |   {=SUM(ABOVE)}  | <(Cell A6)
   |------------------|

Method 2: Use cell references

For a range that contains one or more blank cells, use cell references to define the range instead of ABOVE, BELOW, LEFT, or RIGHT. For example, use the following formula field to obtain a correct result:

   |------------------|
   |               3  | <(Cell A1)
   |------------------|
   |                  | <(Cell A2)
   |------------------|
   |               4  | <(Cell A3)
   |------------------|
   |                  | <(Cell A4)
   |------------------|
   |               5  | <(Cell A5)
   |------------------|
   |   {=SUM(A1:A5)}  | <(Cell A6)
   |------------------|

REFERENCES

"Microsoft Word User's Guide," version 6.0, pages 306-311

Additional query words: kbusage kbfield kbtable

Keywords          : wordnt kbfield kbtable word6 word7 word95 word 
Version           : 6.00 6.00a 6.00c 7.00 7.00a
Platform          : WINDOWS
Issue type        : kbbug
Solution Type     : kbpending

Last Reviewed: May 2, 1998