G.8. The Control Object

Within a form, you can have a variety of different controls. You use them to display data from tables, queries, and other data sources such as ADO recordsets. Every control in Access derives from the Control object.

G.8.1. Control Object Properties

The Control object has quite a few properties, which are described in the following table.

PropertyData TypeDescription
ApplicationApplication objectReturns the currently active Application object.
BottomPaddingIntegerSpecifies the amount of space between a control and its bottom gridline.
ColumnVariantRefers to a specific column in a combo box or listbox.
ControlsControls collectionRefers to the collection of all the controls on the form.
FormForm objectRefers to the current form object.
GridlineColorLongSpecifies the color for control gridlines in a stacked or tabular layout.
GridlineStyleBottomByteSpecifies the style for the bottom gridline for a control.
GridlineStyleLeftByteSpecifies the style for the left gridline for a control.
GridlineStyleRightByteSpecifies the style for the right gridline for a control.
GridlineStyleTopByteSpecifies the style for the top gridline for a control.
GridlineWidthBottomByteSpecifies the width of the bottom gridline for a control.
GridlineWidthLeftByteSpecifies the width of the left gridline for a control.
GridlineWidthRightByteSpecifies the width of the right gridline for a control.
GridlineWidthTopByteSpecifies the width of the top gridline for a control.
HorizontalAnchorAcHorizontalAnchor ...

Get Access™ 2007 VBA Programmer's Reference now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.