How to Automatically Populate Form Fields in Microsoft Access
Question details
The user wants to automatically populate a subject's address and other details into new case records when a subject is selected, avoiding manual data duplication.

- Product
- Microsoft Access
- Device & OS
- not provided
- Scenario
- Designing a data entry form for new case records where related subject details need to be displayed automatically upon selecting a subject.
- Observed behavior
- Without proper relational structuring, users are forced to repeatedly duplicate subject information manually across multiple case records.
Before modifying your database forms, review your current table schema to clearly identify which fields belong to the subject and which belong to the case, ensuring you have designated primary keys for both entities.
Restructure Tables and Use a Main Form with a Subform
The most reliable way to handle related details without duplicating data is to normalize your tables and link them using a main form and a subform.
By splitting your data into separate Subject and Case tables, you ensure that subject details are only stored once. The forms can then be linked visually to make data entry seamless.
Navigate to the Create tab and click Table Design. Add fields for FirstName, LastName, Address, City, and State. Assign an AutoNumber field as the Primary Key and save it as the Subject table.
Create another table for case information. Include a Primary Key for the case, and add a Number field named 'SubjectID' to serve as the Foreign Key.
Go to Create > Form Wizard and create a main form bound to your Subject table. This form will act as the master view for the subject's details.
Open the Main Form in Design View. Select the Subform/Subreport control from the Form Design ribbon and draw it on your form, binding it to the Case table.
Select the subform control and open the Property Sheet. Under the Data tab, set both the 'Link Master Fields' and 'Link Child Fields' properties to 'SubjectID'.

Use a Combo Box to Auto-Fill Data on a Single Form
If you prefer to enter cases on a single, continuous form, you can use a combo box to select the subject and use expressions to display their stored details.
Need a Free Alternative for Your Daily Office Tasks?
While Microsoft Access requires a paid subscription for database management, WPS Office provides a powerful, free alternative for your everyday document, spreadsheet, and presentation needs. With a highly familiar interface, it ensures a seamless transition for Microsoft Office users.
- 1. Download and Install: Get WPS Office for free from the official website and install it on your PC, Mac, or mobile device in just a few minutes.
- 2. Import Your Data: Export your Access data as an Excel file and open it seamlessly in WPS Spreadsheets.
- 3. Use Advanced Functions: Utilize powerful features like VLOOKUP and PivotTables to manage tabular data and create cross-references easily.

Frequently Asked Questions
Why is my Access form duplicating data when creating a new record?
This usually happens due to a flat or unnormalized table structure. Instead of saving customer details directly into every single case record, you should separate the data into different tables (e.g., Subject and Case) and link them using a primary key.
What are Link Master Fields and Link Child Fields in Microsoft Access?
These properties are used in subforms to synchronize records between two linked tables. The 'Link Master Fields' refers to the primary key in the main form, and 'Link Child Fields' refers to the corresponding foreign key in the subform.
Can I auto-populate text boxes using a combo box selection?
Yes. You can add extra columns to your combo box's Row Source query and use expressions like `=[YourComboBoxName].[Column](Index)` as the Control Source for your unbound text boxes to display that data automatically.
Should I use an AutoNumber for my primary key in Microsoft Access?
Yes, using an AutoNumber data type for primary keys is highly recommended. It guarantees a unique identifier for each record automatically, which is essential for properly linking tables with foreign keys.




