Just like my tittle says, on my main form I have a navigation control with a button to form in subject.
So, here's the structure of the issue:
This setup allows me to type in the
Issue is when navigating from main form to
This is because the form is not opened.... yet. Once I click on "End" on prompt, everything loads and works.
What is the most elegant solution to this without having to open the subform
So, here's the structure of the issue:
frm_Main contains:- Nav Control with button to
frm_Members
frm_Members contains:- Search box
txt_Searchwith code:-
Code:
Private Sub txt_Search_Change() Me.txt_TempSearchData = Me.txt_Search.Text Me.NavigationSubform.Requery End Sub
-
- Temporary text field
txt_TempSearchData - Another Nav Control with a subform
frm_UserList(frm_UserList is based on qry_UserQuals)
qry_UserQuals contains custom field SearchTerms:- Main field is
SearchTerms: [LastName] & [FirstName] - Criteria is
Like "*" & [Forms]![frm_Main]![NavigationSubform]![txt_TempSearchData] & "*"
This setup allows me to type in the
txt_Search and it will search and filter subform frm_UserList as I type.Issue is when navigating from main form to
frm_Members I get an error where it cannot find frm_Members.This is because the form is not opened.... yet. Once I click on "End" on prompt, everything loads and works.
What is the most elegant solution to this without having to open the subform
frm_Members hidden? Best way to handle this?