0
votes

I am currently running into an issue where a form dependent upon on a query appears blank.

My form whose record source is a query contains a list box whose selected value is the parameter for the query field “Account Name”.

To get it to work, I have been opening the record source query in Design View and removing the parameter on Account Name. I then open the “linked” form and all the Account Names in my list and all fields appear again. While keeping the form open in a separate tab, I then re-open the design view of the record source query and add the parameter Criteria back in: “[Forms]![frm_All Info Dropdown]![List26]. Now, if I switch back to the form which has remained open the entire time in a separate tab as I added the parameter back into the query, I am able to run multiple queries and reports from my form, filtered by the Account Name selected in the list, that produce the correct results with no problem using buttons with embedded macros that include re-queries.

The issue then re-presents itself once I completely close the form and try to reopen it. The form then appears blank again. Based on my troubleshooting and novice understanding, I believe this is likely because the query is now no longer “blank” (ready for any Account Name to be used as a parameter) and is thus possibly dependent upon an empty parameter, causing the form to display as blank due to “no records to display”. I of course understand this could be wrong though.

I do not know how to go about fixing this. Ideally, I would like to have a button on my “Home” form that allows me to open my form that is dependent upon a query and uses a list box as parameter without issue. I would then like to be able to close them completely, return to Home, and repeat the process if needed.

The queries contain information from multiple tables which are joined. I manually typed in the values of the 17 account names I needed when creating the list box on my form.

I found the following article: http://allenbrowne.com/ser-61.html but am still confused. If it is a “read-only” query I do not know how to fix it. Any help is very much appreciated.

1
If you add OR [Forms]![frm_All Info Dropdown]![List26] is Null to your query criteria, it might work. Try it and let us knowMinty
That did fix the problem. Thank you so much for your help and quick response!Peyton C

1 Answers

0
votes

If you add

OR [Forms]![frm_All Info Dropdown]![List26] is Null 

to your query criteria, it should work as a logical switch for no entry.