About creating controls

Microsoft Office Access 2003

  • A bound control is tied to a field in an underlying table or query. In a Microsoft Access project, a control can be bound to a field in a view or stored procedure. If the Access project is connected to a database in Microsoft SQL Server 2000, a control can also be bound to a field in a function. You use bound controls to display, enter, or update values from fields in your database.

  • An unbound control doesn't have a data source. You can use unbound controls to display information, lines, rectangles, and pictures.

  • A calculated control uses an expression as its source of data. An expression can use data from a field in an underlying table or query of a form or report, or from another control on the form or report.

Bound, unbound, and calculated controls

Callout 1 These bound controls get their data from the ProductName and UnitPrice fields in the Products table.

Callout 2 This calculated control uses the following expression as its data source: =[UnitPrice]*.75. You specify the expression in the ControlSource property box.

Callout 3 Unbound controls such as this rectangle and freestanding label don't have data sources.

ShowAbout ways to create controls

In a form or report that is based on a record source, or in a data access page that is connected to a database, you can create a control by dragging a field from the field list. Microsoft Access creates the appropriate control for the field and sets certain properties, based on the field's data type.

If you want to specify the type of control you want, you can create the control by clicking the appropriate control tool in the toolbox. Then you can specify the properties of the control yourself, or you can use a wizard to create the control.

On forms and reports, you can use wizards to create command buttons, list boxes, subforms, combo boxes, and option groups. On data access pages, you can use wizards to create list boxes and drop-down list boxes. Wizards are not available in a stand-alone data access page, or in a data access page that is connected to a database other than the one currently open.