Others

Pass a Value Between Microsoft Access Subforms Using the Form Property

Maira MehtabMaira Mehtab Nov 20, 2026 868 views

Question details

The user needs to pass a control value from one subform to another on the same Microsoft Access main form.

Pass a Value Between Microsoft Access Subforms Using the Form Property
Product
Microsoft Access
Device & OS
not provided
Scenario
Two subforms are displayed on one main form, and an action in the source subform should update a control in the destination subform.
Observed behavior
Referencing a control inside a subform directly may cause an object or property error; the subform control's Form property provides access to its controls.
Before you start

Open the main form in Design View and check the destination subform control's Name in its Property Sheet; it may differ from the form object name. Also identify the source and destination control names and make sure the destination control is editable.

Solution 1Recommended

Use the Form Property to Set a Value in the Destination Subform

Use this method when both subforms are open on the main form and you want to update a control on the destination subform's current record.

1
Open the source event

Open the source subform in Design View, select the source control, and choose Property Sheet > Event > On Dbl Click. Select [Event Procedure], then click the ellipsis button to open the VBA editor.

2
Add the assignment

Inside the generated double-click event procedure, add: Forms!MainFormName!subform1Control.Form!targetControl = Me!sourceControl. Replace MainFormName with the open main form's name, subform1Control with the destination subform control's Name, and the control names with your actual names.

3
Test the transfer

Save the form, open the main form in Form View, and double-click the source control. Check that the destination control displays the value on its current record.

Use the Form Property to Set a Value in the Destination Subform
Bound controls and saved records: If the destination control is bound to a field, the assignment edits the destination form's current record and is subject to its edit and validation rules. Save the record through the destination form when appropriate; requerying before saving may discard an unsaved edit.
Free Microsoft Office alternative

Work With Exported Access Data in WPS Office

WPS Office is a free, lightweight alternative for working with exported data and documents in a familiar interface. Export Access data to an Excel file to continue working with it in WPS Spreadsheets; WPS does not replace Access subforms or VBA database functionality.

Review and edit data exported from Access in WPS Spreadsheets.Compatible with Microsoft Excel XLSX and Word DOCX files.Familiar spreadsheet and document interfaces make everyday work easy to navigate.A free, lightweight suite for common office tasks.
microsoft office alternative - wps office

Frequently Asked Questions

Why do I need the Form property in a subform reference?

The subform control is a container on the main form. Use its Form property to reach the form it displays and then reference a control, as in Forms!MainFormName!subform1Control.Form!targetControl.

How do I find the subform control name?

Open the main form in Design View, select the subform container, and check Name on its Property Sheet. Use that name in the reference, even if it differs from the name of the form displayed inside it.

Which destination record does the assignment change?

The assignment changes the control on the destination subform's current record. If the control is bound, Access applies the destination form's edit and validation rules when the record is saved.

When should I use an UPDATE query instead?

Use an UPDATE query when you need to update a specific table record rather than assign a value to the destination form's current control. Include criteria that identify the intended record, run the query, and requery the destination subform to display the updated data.