View some of the ways to change control properties.
Custom Form Properties
In Microsoft Access 365, there are several ways to change the properties of controls (like text boxes, combo boxes, buttons, etc.) in forms and reports. Here are some of the common methods:
Property Sheet:
Accessing the Property: Sheet: Select the control on your form or report, then right-click and choose "Properties," or click the "Property Sheet" button in the "Design" tab of the Ribbon.
Using the Property Sheet: The Property Sheet displays all properties for the selected control, organized into categories like "Format," "Data," "Event," etc. You can directly edit the properties from here, such as changing the control's background color, font size, or data source.
Ribbon Commands:
Formatting Tools: The "Format" tab in the Ribbon provides quick access to formatting properties for the selected control. You can change font styles, colors, sizes, and other appearance-related properties directly from here.
Event Handling: The "Event" tab in the Property Sheet allows you to assign event procedures, macros, or expressions to control events like "On Click," "On Change," etc.
Direct Manipulation:
Resizing and Moving: You can click and drag the control to move it around on the form or report. Similarly, you can drag the edges to resize the control.
Context Menu: Right-clicking on a control also gives you quick access to common properties and actions, such as cutting, copying, pasting, and accessing the Property Sheet.
Using VBA (Visual Basic for Applications):
Programmatically Changing Properties: You can write VBA code to change the properties of controls at runtime. For example:
Me.TextBox1.BackColor = RGB(255, 255, 0)
Me.ComboBox1.RowSource = "SELECT Name FROM Employees"
Dynamic Property Changes: This method is particularly useful for making dynamic changes based on user interaction or other logic within your application.
Macros:
Automating Property Changes: You can create macros that change control properties based on specific conditions or events. For example, a macro could change the visibility of a control when a button is clicked.
Macro Builder: The Macro Builder in Access allows you to visually create these automation rules without writing VBA code.
Conditional Formatting:
Visual Rules: For controls like text boxes or combo boxes, you can use Conditional Formatting to change properties like font color, background color, and boldness based on certain conditions (e.g., if a value is greater than a certain number).
Accessing Conditional Formatting: You can access this option through the "Format" tab when a control is selected.
These methods give you flexibility in customizing the appearance and behavior of controls in Microsoft Access 365, making it easier to create user-friendly and functional forms and reports.
Changing Individual Controls properties
As with forms, individual controls have properties that can be modified to customize forms for users convenience.
To change an individual controls properties, first open the property sheet for the control. To accomplish this, click the control, then click the Properties toolbar button.
You will then see the properties for that control. Note that the properties displayed will depend on the type of control you are working with.
For example, a Label Type control will have different properties than a Combo Box control. You can see the Format tab of the property sheet for a label displayed here:
As with form properties, the changes made to properties of controls take effect the next time the form is displayed in Form view. Although you can change the caption of a Label control by using the property sheet, there is an alternative way
Changing label's Caption Property
There is an alternative way to the property sheet for changing a labels caption property. That method is to simply double-click in the
Label control itself. You can then type the change you want.
You can change the label caption that is automatically entered when you add a field to a report in Microsoft Access.
A caption is one of the properties of a label control in Microsoft Access. Properties store the text, size, color, source, behavior and appearance of controls.
In an Access report, the caption property stores the text that displays on the report.The caption property is also available in the table and form design views.
Open Microsoft Access. Click "File" and "Open" in the top menu.
Highlight the database file you want to open. Click the "Open" button.
Select "Reports" from the "Objects" pane. Highlight the report in the right pane. Click "Design" in the toolbar.
Right-click on the label. Select "Properties" from the menu.
Click the "Format" tab on the "Label" window. Delete the text from the "Caption" field. Type a new label caption.
Click the "X" in the upper right corner of the "Label" window to close it. Click "File" and "Save" to save your changes.
Changing Properties for more than one control
When working with one control, you can easily change the properties. For multiple controls, the process gets a bit more complicated. To change multiple controls, hold down the Shift key and click on the additional controls you want to change.
Once you have highlighted the controls you want, the property sheet displays Multiple selection at the top instead of a control name.
The property sheet reflects only properties that are common to all the controls highlighted. Now, stay tuned for the next lesson to continue to manipulate multiple controls. In the next lesson, you will learn how to work with multiple controls and how to align and size them all at once.