Microsoft KB Archive/304461

= ACC97: Formatting and Printing a Table in Microsoft Access =

Article ID: 304461

Article Last Modified on 1/31/2007

-

APPLIES TO


 * Microsoft Access 97 Standard Edition

-



This article was previously published under Q304461



Novice: Requires knowledge of the user interface on single-user computers.

This article applies to a Microsoft Access database (.mdb) and to a Microsoft Access project (.adp).

For a Microsoft Access 2000 version of this article, see 304460.



SUMMARY
This article shows you how to format a table, and then how to print it.



MORE INFORMATION
CAUTION: If you follow the steps in this example, you modify the sample database Northwind.mdb. You may want to back up the Northwind.mdb file and follow these steps on a copy of the database.

 Start Microsoft Access, and then open the sample database Northwind.mdb. Open the Customers table in Datasheet view. With the Customers table open in Datasheet view, try any of the following formatting techniques.

NOTE: Any formatting that you apply is applied to all rows and all columns.

Changing the Font  On the Format menu, click Font. In the Font box, select the font, font style, and size that you want. Under Effects, you can choose to underline the text by clicking the check box for Underline. To change the color of the font, click the color that you want in the Color box.</li> A sample of what the text will look like with the changes that you made to the font is shown under Sample.</li> You can change the script by selecting the script from the drop-down list.</li> Click OK to apply the changes.

NOTE: The font is changed for the Column headings as well as for all the data.</li></ol>

Formatting the Cell Effect and Gridlines of the Datasheet

<ol> On the Format menu, click Datasheet.</li> In the Datasheet Formatting dialog box, you can change the effect of the cells to Flat, Raised or Sunken. If you change the Cell Effect to Raised or Sunken, the Gridlines Shown options become unavailable.</li> If you want to print your table without gridlines, click to clear the Horizontal and Vertical check boxes under Gridlines Shown.</li> To change the color of the gridlines and the background, select the color that you want from the list under Gridline Color and Background Color, respectively.</li> You can also change the border and line style by choosing the border and line style that you want from the list.</li> Click OK to apply the changes.</li></ol>

Changing the Row Height

<ol> On the Format menu, click Row Height.</li> In the Row Height dialog box, type the height that you want. The standard height depends on the type and size of the font that you are using.</li> If you modify the row height and you want to bring it back to the standard height, click to select the Standard Height check box.</li> Click OK to apply the changes.</li></ol>

Changing the Column Width

<ol> On the Format menu, click Column Width.</li> In the Column Width dialog box, type the width that you want. The standard width depends on the type and size of the font that you are using. The standard width is the same for all the columns and is based on the first column. If you select Best Fit, each column is sized based on the text for that column.</li> Click OK to apply the changes.

NOTE: If you set the column width to 0, the column is hidden. To bring the column back, follow the steps in &quot;Hiding and Unhiding a Column&quot; section later in this article.</li></ol>

Renaming the Column Headings

<ol> <li>Place the mouse pointer in the column that you want to resize.</li> <li>On the Format menu, click Rename Column.</li> <li>Type the name that you want for the column, and then press ENTER.

'''

NOTE''': When you change a column heading, you are changing the field name and not the caption. The caption is then removed for the field.</li></ol>

Hiding and Unhiding a Column

<ol> <li>Place the mouse pointer in the column that you want to hide.</li> <li>On the Format menu, click Hide Columns.</li> <li>To unhide the column, click Unhide Columns on the Format Menu.</li> <li>In the Unhide Columns dialog box, click the check box for the columns that you want to be visible, and then click Close.</li></ol> </li></ol>

Printing a Table
To print a table, follow these steps:
 * 1) Open the Customers table in Datasheet view.
 * 2) On the File menu, click Page Setup.
 * 3) In the Page Setup dialog box, click the Margins tab. Note that you can adjust the page margins to increase or decrease the information that is printed on each page.
 * 4) Click the Page tab and note that you can set the Orientation to Portrait or Landscape, depending on how you want to see your information printed.
 * 5) On the File menu, click Print.
 * 6) You can choose to print all pages, selected pages, or selected records, based on the option that you select for Print Range.
 * 7) Click OK to print the table. Note that the table is printed with the formatting options that you have applied.

<div class="references_section">