SteveL13
asked on
Can't get listbox on a form to requery
I have a form which contains a listbox. When the use double-clicks in the listbox a 2nd form opens for data entry. When the 2nd form closes I have this code on the onclose event but the listbox on the main form is not "refreshing". It looks empty yet if I close the main form and re-open the main form the listbox records are there.
Here's my onclose code of the 2nd form:
Forms!frmDailyFinishingInp ut.[List0] .Requery
What am I doing wrong?
--Steve
Here's my onclose code of the 2nd form:
Forms!frmDailyFinishingInp
What am I doing wrong?
--Steve
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
If you use a naming convention, you will never have to guess about whether a name refers to a form, control or other object. That is one of the advantages of using a naming convention. I have an add-on that semi-automatically applies the Leszynski Naming Convention (LNC) to database objects and controls. Here are links for downloading it:
Access 2000-2003 version:
http://www.helenfeddema.com/Files/code10.zip
Access 2007-2010 version:
http://www.helenfeddema.com/Files/code63.zip
Access 2000-2003 version:
http://www.helenfeddema.com/Files/code10.zip
Access 2007-2010 version:
http://www.helenfeddema.com/Files/code63.zip
Forms!frmDailyFinishingInp
"YourSubformCONTROL" is the name of the Subform CONTROL on frmDailyFinishingInput. It may or may not be named the same as the form you're using as a SourceObject, so be sure to verify this.