If you use a continuous subform, simply use an on-click event on the subforms details section.
1.Click inside the details section and go to the Event tab of the property side bar.
2.Go to "On Click" and choose the code generator to enter vba to automatically get the basic environment for your process
3.Paste the following code and modify it to your needs.
DoCmd.GoToRecord acDataForm, "yourmainform", acGoTo, sub_fieldname
Imagine you have the following settings:
frm_contact is your main form.
sub_contactlist is your subform showing all the listed names
contact_id is the unique identifier of your forms (both main and subform)
The final result of sub_contactlist's detail section should look like this.
Private Sub Detail_Click()
DoCmd.GoToRecord acDataForm, "frm_contact", acGoTo, contact_id
End Sub
"contact_id" refers to the current contact entry inside the subform. It might also be named differently. You could also use "Me.contact_id" for clarity purposes. The code will jump to the entry where the unique identifier matches the offset (in this case: contact_id).
In case you would not use the detail section subform but a button or anything alike on the mainform, you could even leave the "acDataForm" and "frm_contact" blank.
Note: I generally advice to omit spaces when dealing with codes whenever possible. In case you have spaces in your names, put them in square brackets. Otherwise you'll get an error. Some people use square brackets in general to somehow highlight their fields within the code. I don't.