Chapter 5. Formatting

Number, Date

Abstract

Format cells to display numbers to a specific number of decimal places, to display numbers with, without commas to indicate thousands

Suppose we have the spreadsheet Sales.sxc on our screen as shown below.

This illustrates a common problem, namely that it is sometimes difficult to read large numbers. Calc allows us to format numbers with a decimal separator.

  1. Highlight the numbers to be formatted.

  2. Format->Cells

  3. Click the Number tab.

  4. Select General.

  5. Tick the Thousands separator check box.

  6. Click OK.

    The result is shown on the next screen.

To remove the thousands separator:

  • Repeat the above process, but untick the Thousands separator check box.

Decimal Places

You can also instruct Calc to display specific decimal places. In the above screen this option is set to display 0 decimal places. (Look at Decimal Places under Options). You can change the value either by typing in a new value or by clicking on the arrows next to the box to either increase or decrease the value.

Format cells to display a date style

If you type data into a cell, Calc attempts to interpret the data according to one of its known data types. These include numeric, text and date.

  • Type the entry 3/11/2003 into a cell in a blank spreadsheet.

Calc will interpret this as a date and reformat it according to its default date setting. For example, as soon as you press enter, the display of the above cell could become 3/11/03.

The following screen illustrates this. The input window on the Formula bar shows the actual data entry, while the cell illustrates how it has been reformatted.

To change the format of the cell

  1. Select the cell to be reformatted.

  2. Format->Cells

  3. Click the Numbers tab.

  4. Select Date in the Category window.

  5. Select the date format in the Format window.

  6. Click OK.

Format cells as currency style

If we look at the example in the section called “Number, Date” we see that although some of the figures refer to currency, the currency symbol is not displayed. This is simply remedied by formatting numeric data to currency format.

  1. Select the range of cells to be formatted as currency.

  2. Format->Cells

  3. Click the Numbers tab.

  4. Select Currency in the Category window.

  5. Select a language in the Language window. This will select the appropriate currency symbol.

  6. Select the desired format in the Format window.

  7. Click OK.

Format cells to display numbers as percentages

The next screen shows the previous spreadsheet with the profit calculated as a fraction.

In situations such as this it is more common to express the numbers in E5:E8 as percentages.

  1. Select the numbers to be formatted.

  2. Format->Cells

  3. Select the Numbers tab.

  4. Select Percent in the category window.

  5. Select the Number of decimal places in the Options area.

  6. Set any other options.

  7. Click OK.