B
BBC via AccessMonster.com
I have a parent form that has full detail of a Registration record for one
selected Franchise (for editing purposes). Below I have a subform showing
all the registration records associated with the current selected franchise.
The records in the subform are linked to the parent by their FranchiseID so
selecting a Franchise (from a combobox) displays the associated records in
the subform. The Registration records have a normal autogenerated primary
key (not the FranchiseID which is the Franchise's primary). Fields are bound
to the parent form.
I want to be able to click on any one of the listed subform rows and have
that data appear in the top part of the form (and then preferably change
focus back to a field on the parent for editing). I have tried numerous
methods such as.
using the subform current event to try to find the associated record such as;
me.parent.recordset.FindFirst "[id]=" & ID (or me.parent!recordset.
FindFirst "[id]=" & ID)
me.parent!comments.setfocus
-or setting the subform ID to a field on the parent (works) then trying to
set focus back to that field on the parent form and using its gotfocus to do
a findfirst (ignores the setfocus from the subform)
etc.
Suggestions please
selected Franchise (for editing purposes). Below I have a subform showing
all the registration records associated with the current selected franchise.
The records in the subform are linked to the parent by their FranchiseID so
selecting a Franchise (from a combobox) displays the associated records in
the subform. The Registration records have a normal autogenerated primary
key (not the FranchiseID which is the Franchise's primary). Fields are bound
to the parent form.
I want to be able to click on any one of the listed subform rows and have
that data appear in the top part of the form (and then preferably change
focus back to a field on the parent for editing). I have tried numerous
methods such as.
using the subform current event to try to find the associated record such as;
me.parent.recordset.FindFirst "[id]=" & ID (or me.parent!recordset.
FindFirst "[id]=" & ID)
me.parent!comments.setfocus
-or setting the subform ID to a field on the parent (works) then trying to
set focus back to that field on the parent form and using its gotfocus to do
a findfirst (ignores the setfocus from the subform)
etc.
Suggestions please