Forum Discussion
AmedMesa
Nov 10, 2020Copper Contributor
Filtered listbox with selected item to open record.
I have a listbox I have doing two things. It filters criteria based on a Textbox.Text with an OnChange event. Code works beautifully individually! Plenty of tutorials using a WHERE in an SQL state...
Tim_Marshall
Nov 10, 2020Copper Contributor
AmedMesa Hello, Amed, just a quick thought on the memory message. This may be obvious, but have you restarted your computer? I have found in previous versions of Access and on O/S before Win 10 (which I am only starting to use these past couple of weeks) that sometimes my computer would get "tired" and require a reboot. I've frequently encountered situations where MS Access would not even start, citing "not enough memory". Restarting the computer has always made such memory error messages disappear.
--
Tim
AmedMesa
Nov 10, 2020Copper Contributor
Tim_Marshall
Appreciate the response. I don't think it is my computer given I have done this on two entirely different PCs. I have repeated this error using the same coding but written in separate db files individually. Negates a file corruption question.
When I close the form I can use the OnDblClick event on the listbox as intended to pass through the selected item to the WHERE clause of the SQL statement in the other form.
I get this problem when I apply a filter to the listbox based on the TextBox.Text on the OnChange event. Again, it filters the items perfectly. But, once I filter it I cannot copy the contents of what I select, though I can select any item on that list as normal. It just does not update the object properties it seems. Its blank. the ListBox.Value or .Column() is empty no-matter what.