XL98: Overlapping Formatted Cell Border Behavior (188504)



The information in this article applies to:

  • Microsoft Excel 98 Macintosh Edition
  • Microsoft Excel for the Macintosh 5.0

This article was previously published under Q188504

SUMMARY

When the formatted borders of cells are adjacent, you may observe different behavior based on which version of Microsoft Excel you are using. This article discusses the different behaviors that you may observe.

MORE INFORMATION

When you format cell borders in Microsoft Excel and the borders are adjacent, the version of Excel determines what kind of behavior you observe.

For Microsoft Excel 98 Macintosh Edition, the most recently applied style or color border format takes precedent. For example, if you select cell B5 and apply the solid thick border format with the color black, and then you select cell B6 and apply the solid thin border format with the color yellow, the adjacent border format between the cells B5 and B6 will be thin and yellow. If you then select cell B5 and re-apply the solid thick border format with the color black, the adjacent border format between cells B5 and B6 will be the solid thick black format because this format is now the last border format you applied.

To illustrate this behavior, do the following:
  1. From Excel 98 Macintosh Edition, in a new workbook select cell B5.
  2. On the Format menu, click Cells to display the Format Cells dialog box. Click the Border tab.
  3. In the Style group, select the solid, thick border format located just above the double line in the right column of border styles, with the color black. Click Outline, and then click OK. 188503188503 Cell B5 should now have a thick, black border.
  4. Select cell B6 and on the Format menu, click Cells to open the Format Cells dialog box. Click the Border tab.
  5. In the Style group, select the solid thin border format located at the bottom of the left column of border styles, with the color yellow. Click Outline, and then click OK. 188503188503 Cell B6 should now have a thin, yellow border. The adjacent cell edge between cells B5 and B6 should now be thin and yellow.
To give border precedence back to cell B5, do the following:
  1. Select cell B5. On the Format menu, click Cells to open the Format Cells dialog box. Click the Border tab.
  2. In the Style group, select the solid thick border format from the right column of border styles just above the double line with the color black. Click Outline, and then click OK. 188503188503 The adjacent cell border between cells B5 and B6 should now be solid, thick, and black.
Microsoft Excel 5.0 has the following cell border precedence:
   Style         Weight    Strength
   =====         ======    ========
   Double        Thin          7
   Solid         Thick         6
   Solid         Medium        5
   Solid         Thin          4
   Dash          Thin          3
   Dot           Thin          2
   Solid         Hairline      1
				
The following list shows the color precedence for Excel 5.0, from greater to lesser precedence:

Black
Dark Blue
Blue
Dark Red
Red
Dark Green
Magenta
Dark Cyan
Light Brown
Green
Cyan
Yellow

Darker colors typically get precedence over lighter colors and style border format has precedence over color border format.

For example, if you select cell B5 and apply the solid thick border format with the color yellow, and then you select cell B6 and apply the solid thin border with the color black, the adjacent border format between cells B5 and B6 will be thick and yellow because the solid thick border format has greater precedence even though the color yellow has lesser precedence. Color precedence will only be a factor when the style border formats or the adjacent cells are the same.

To illustrate border precedence order, do the following:
  1. In a new workbook from Excel 5.0, select cell B5.
  2. On the Format menu, click Cells to activate the Format Cells dialog box.
  3. Click the Border tab to display the Border sheet.
  4. In the Style group, select the solid thick border format located at the bottom of the left column with the color black. Click Outline, and then click OK.

    Cell B5 should now have a thick, black border.
  5. Select cell B6 and on the Format menu, click Cells to activate the Format Cells dialog box.
  6. On the Border sheet in the Style group, select the solid thin border format located at the top of the left column with the color yellow. Click Outline, and then click OK.

    Cell B6 should now have a thin, yellow border but the adjacent cell edge between cells B5 and B6 is still thick and black because the solid thick border has precedence over the solid thin border.
To illustrate color precedence order, do the following:
  1. In a new workbook from Excel 5.0 select cell B5.
  2. On the Format menu, click Cells to activate the Format Cells dialog box.
  3. Click the Border tab to display the Border Sheet.
  4. In the Style group, select the solid thick border format. located at the bottom of the left column with the color yellow. Click Outline, and then click OK.

    Cell B5 should now have a thick, yellow border.
  5. Select cell B6 and on the Format menu, click Cells to open the Format Cells dialog box.
  6. On the Border sheet, in the Style group, select the same border format from step 4, except with the color black. Click Outline, and then click OK.

    Cell B6 should have a thick, black border and the adjacent cell edge between cells B5 and B6 should now be thick and black because the color black has precedence over the color yellow.

REFERENCES

For more information about cell borders, click Contents And Index on the Help menu (or on the Balloon Help menu if you are using a version of the Macintosh operating system earlier than 8.0), click the Index button in Microsoft Excel 98 Help, type the following text

borders, cells

and then click Show Topics. Select the "Apply borders to cells" topic, and click Go To. If you are unable to find the information you need, ask the Office Assistant.

Modification Type:MajorLast Reviewed:9/11/2002
Keywords:kbhowto KB188504