Microsoft KB Archive/26273

{| = Excel: Numbers Don't Expand into Adjacent Cells =
 * width="100%"|

Last reviewed: November 2, 1994

Article ID: Q26273

SUMMARY
If a decimal number is too long to fit within a column in Microsoft Excel, the decimal portion will round to the number of digits that will fit within the column. If the integer portion of a number will not fit within the column, number signs (#) will appear in the cell.

To format a number so that it will expand into an adjacent cell if the number is too long to fit within the column, the number must be converted to a text string. Text strings will automatically expand into adjacent cells if those adjacent cells do not contain any data.

The formula &quot;=TEXT(value,format_text)&quot; can be used to convert a number into a text string, where &quot;value&quot; is a number or formula and &quot;format_text&quot; is a number format embedded in quotation marks.

For example, to format the result of the formula =SUM(B1:B10) as a text string in the format &quot;$#,##0.00 ;($#,##0.00)&quot;, use the following formula:

=TEXT(SUM(B1:B10),&quot;$#,##0.00 ;($#,##0.00)&quot;)
 * }