belly0fdesir
11-01-2007, 05:10 PM
Hello.
I'm using a modified version of Allen Browne's DirListBox() function (http://allenbrowne.com/func-02.html).
Instead of just referring to a folder location in the code, I'm using criteria supplied by the user on a form. The problem is that the listbox only clears when the database is closed and then re-opened. I would like to add some code either to the beginning of the code I have (which populates the listbox when the user clicks a "Search" button) or add some code to a "Clear List" button.
But I don't know how to clear it without closing and re-opening the database. I've tried several things, but they all just clear and then repopulate with what was there before. And when the user enters different criteria, it just adds it to the list underneath the files that were already listed.
Does this make sense? Does anyone know how I would go about clearing this for a fresh search without closing and re-opening the database?
Please? Thank you :)
I'm using a modified version of Allen Browne's DirListBox() function (http://allenbrowne.com/func-02.html).
Instead of just referring to a folder location in the code, I'm using criteria supplied by the user on a form. The problem is that the listbox only clears when the database is closed and then re-opened. I would like to add some code either to the beginning of the code I have (which populates the listbox when the user clicks a "Search" button) or add some code to a "Clear List" button.
But I don't know how to clear it without closing and re-opening the database. I've tried several things, but they all just clear and then repopulate with what was there before. And when the user enters different criteria, it just adds it to the list underneath the files that were already listed.
Does this make sense? Does anyone know how I would go about clearing this for a fresh search without closing and re-opening the database?
Please? Thank you :)