Hello,
I have a main form (Offices) with 2 subforms (State) and (Details).
The State subform contains a list of offices in that State in a continuous form so I see all 12 offices in the subform at once.
I want to be able to click on the OfficeName field in the State subform and have it update the Details subform to only display the related records for that office eg address, site contact etc.
All forms use the same query as their source which contains tables linked by OfficeID.
I have created an onclick event for the OfficeName field, but I am unsure of the underlying code to accomplish what I am after.
I assume what is required will be:
Click on OfficeName
Set current record to record that contains the OfficeName I just clicked on
SetFocus to Details subform
Requery Details subform so only the records where OfficeID field matches are displayed.
I hope someone can point me in the right direction and/or suggest the correct functions to do what I am after.
Any assistance is much appreciated.
I have a main form (Offices) with 2 subforms (State) and (Details).
The State subform contains a list of offices in that State in a continuous form so I see all 12 offices in the subform at once.
I want to be able to click on the OfficeName field in the State subform and have it update the Details subform to only display the related records for that office eg address, site contact etc.
All forms use the same query as their source which contains tables linked by OfficeID.
I have created an onclick event for the OfficeName field, but I am unsure of the underlying code to accomplish what I am after.
I assume what is required will be:
Click on OfficeName
Set current record to record that contains the OfficeName I just clicked on
SetFocus to Details subform
Requery Details subform so only the records where OfficeID field matches are displayed.
I hope someone can point me in the right direction and/or suggest the correct functions to do what I am after.
Any assistance is much appreciated.