Microsoft Office Online
Sign in to My Office Online (What's this?) | Sign in

 
 
Microsoft Office Access
Search
Search
 
Updates: (c) Microsoft
Office downloads
 
 
 
Warning: You are viewing this page with an unsupported Web browser. This Web site works best with Microsoft Internet Explorer 6.0 or later, Firefox 1.5, or Netscape Navigator 8.0 or later. Learn more about supported browsers.

Printer-Friendly VersionPrinter-Friendly Version Bookmark and ShareShare
Top tips for Access: Forms, reports, and controls
 
Applies to
Microsoft Office Access 2003
Microsoft Access 2000 and 2002

The following tips will help you work with your forms, reports, and controls. You may want to check in again later—we'll be adding more tips as we go.

Forms and reports

  • To publish a form on the Web, save it as a data access page and then publish the page.
  • In a form, remove a section and its controls by selecting the section and then pressing DELETE.
  • When working with forms, press F5 to quickly switch from Design view to Form view.
  • In a form or report, click the Build button on the toolbar to use the Expression Builder to create an expression.
  • To calculate a value in Access, write an expression using Expression Builder.
  • If you need more room to type a value in the property sheet, press SHIFT+F2 to open the Zoom box.
  • To change the layout of a subform inside a form, click View, point to Subform, and click a view.
  • Create a columnar AutoForm based on the open record source or the record source that's selected in the Database window. Click AutoForm on the Insert menu, or click the arrow next to the New Object button on the toolbar, and then click AutoForm. If the record source you select has related tables, AutoForm adds a subform that contains the related tables displayed as datasheets and subdatasheets.
  • To create a form or report that uses data from multiple tables, base your form or report on a query.
  • To add a calendar to a form: click ActiveX Control on the Insert menu, then click Calendar Control 11.0.
  • On a form, to create or modify a command button that runs a macro, drag the macro from the Database window to form Design view.
  • For a form that allows irreversible operations, such as deletions, it's a good idea to make the Cancel button the default command button. To do this, set both the Cancel property and the Default property to Yes.
  • If you want to make small adjustments to the size of a control in a form or report, you might find it easier to press SHIFT plus the appropriate arrow keys.
  • If you don't want any title bar text for a form or report, type a space in the Caption property box.
  • When you move a control in a form or report, you can maintain its horizontal or vertical alignment with other controls by holding down the SHIFT key while selecting and moving the control. You can move the control horizontally or vertically only, depending on which direction you move it first.
  • To make small adjustments to the placement of a control, you might find it easier to press the appropriate arrow keys. If Snap to Grid is on when you use the arrow keys to move a control, Access aligns the control to the grid.
  • To temporarily override the current Snap to Grid setting, hold down the CTRL key while you're placing, moving, or sizing a control. For example, if Snap to Grid is turned on, you can hold down the CTRL key and move a control anywhere on the form, report or data access page without aligning it to the grid. Releasing the CTRL key restores the current Snap to Grid setting.
  • To get Help on any property in the property sheet, click the property and then press F1.
  • Use the Form Wizard to create two related forms from scratch by using the Linked Forms option.
  • If most records share the same value for a field, save time by setting a Default Value property for the control. When you add a new record, the form will automatically show the default value in that control.
  • Use conditional formatting to make a control unavailable; for example, you can prevent the value it contains from being changed if a specified condition is true.
  • Instead of distributing printed copies of a report, distribute a snapshot of the report created using the Snapshot Viewer.
  • In a report, to print group headings on subsequent pages, set the group header's RepeatSection property to Yes.
  • Right-click a form in the Database window and click Create Shortcut to add a shortcut to the form.
  • To print groups on separate pages, set the group header’s ForceNewPage property to BeforeSection.
  • To move to the next field in a form, press Tab.
  • To move to the previous field in a form, press Shift+Tab.
  • To add a calendar to a form: click ActiveX Control on the Insert menu, then click Calendar Control 11.0.
  • To skip a section when printing a form or report, set the section’s DisplayWhen property to ScreenOnly.
  • To temporarily override the Snap to Grid setting, hold down the CTRL key while moving a control.
Top

Controls and charts

  • To resize a control to fit a font, point to Size on the Format menu and click To Fit.
  • To use the same special effect for another control, click the Special Effect button (you don't have to click the arrow next to the button and pick the effect again from the list).
  • In a form or report, adjust the thickness of a control's shadow by clicking the Line/Border Width button on the Form/Report Formatting toolbar.
  • In a form or report, use the Enabled property together with the AfterUpdate property to disable a control until a user enters text or makes a selection in another control. For example, you might want to disable a command button until data has been entered in a text box. Use the AfterUpdate property of the text box to call an event procedure or a macro to enable the command button.
  • If you're referring to a control on a subform or subreport, you don't have to specify the full identifier for the form or report using the Form or Report property. For example, you can use the following identifier to refer to the Quantity control on the Orders Subform subform:

    Forms![Orders]![Orders Subform]![Quantity]

  • To resize an image control so that its height and width match the dimensions of its picture, point to Size on the Format menu and click To Fit.
  • To use a unit of measure that is different from the setting specified by the regional settings in Microsoft Windows Control Panel, specify that type of measurement after the number (for example, 1.5 in or 2 cm). To disable the control until a certain condition is met, use the Enabled property together with the AfterUpdate property. On forms and reports, to hide or unhide a control in response to an event, use a macro or event procedure to set the Visible property. Attach the macro or event procedure to the OnCurrent property of a form or the OnFormat property of a report. For example, you can show or hide a congratulatory message next to a salesperson's monthly sales total in a sales report, depending on the sales total.
  • To hide a section or control on a form only when you are printing, use the DisplayWhen property.
  • When you move a control in a form or report, you can maintain its horizontal or vertical alignment with other controls by holding down the SHIFT key while selecting and moving the control. You can move the control horizontally or vertically only, depending on which direction you move it first.
  • To make small adjustments to the placement of a control, you might find it easier to press the appropriate arrow keys. If Snap to Grid is on when you use the arrow keys to move a control, Access aligns the control to the grid.
  • To temporarily override the current Snap to Grid setting, hold down the CTRL key while you're placing, moving, or sizing a control. For example, if Snap to Grid is turned on, you can hold down the CTRL key and move a control anywhere on the form, report or data access page without aligning it to the grid. Releasing the CTRL key restores the current Snap to Grid setting.
advertisement