Solved Form Combo Box Not Working Correctly

depawl52

New member
Local time
Yesterday, 20:59
Joined
Feb 8, 2022
Messages
22
So in the attached database, as you can see there is a table and 2 forms. The CustomersList form opens showing general information, and then the CustomerDets form can be opened from the "Open" link on the CustomersList form, which is how the program is supposed to operate. When done this way, the "Go To Company" combo box on the CustomerDets form does not work at all. However when the CustomerDets form is opened directly from the Navigation pane, the combo box works as designed and allows one to select and view another Customer's Details. Been struggling with this for a few days, any suggestions pointing me in the right direction would be most appreciated, I fear it's something simple and obvious that I've overlooked.
Thank you.
 

Attachments

Opening from List, form is filtered to single record. Have to remove this filter before searching for another record. Try adding
Me.Filter = ""
to beginning of AfterUpdate procedure.

The AfterUpdate code does not filter, it goes to. If you did that when form first opens instead of applying filter, the above would not be needed.
 
Hi. Welcome to AWF!

Another option is to re-filter the form rather than navigate to the selected company. Just a thought...
 
Thank you.
Adding me.filter to the AfterUpdate procedure did it.
 
OK, so as a follow up to yesterday, in the same actual database I have an Orders table and forms related to the Customers table and forms discussed above. I've uploaded a trimmed down version with just the Orders portion, which follows the same logic. Now I have the same issue as per yesterday's post. Even after adding the me.filter = "" to the AfterUpdate procedure of the combo box, it does not seem to work correctly. If the DetailsF2 form is opened manually, the combo box operates correctly. If DetailsF2 is called from the "Open" link on the OrdersList form, the combo box does not work. I was literally up half the night working on this with no resolve. Many thanks in advance for any additional guidance.
 

Attachments

Hi. See if the attached helps.
 

Attachments

Thanks so much DBguy. The answer is so simple it's almost embarrassing. At some point after I posted this morning I realized that on this (orders) portion of the database, I actually had the info in a subform, whereas with the Customers portion that I posted yesterday I didn't. But for some reason I thought that in the me.filter statement I had to refer to the subform from the main form, rather than the opposite.
 
Thanks so much DBguy. The answer is so simple it's almost embarrassing. At some point after I posted this morning I realized that on this (orders) portion of the database, I actually had the info in a subform, whereas with the Customers portion that I posted yesterday I didn't. But for some reason I thought that in the me.filter statement I had to refer to the subform from the main form, rather than the opposite.
No worries, so long as you got it to work. Good luck with your project.
 

Users who are viewing this thread

Back
Top Bottom