I'm not sure to understand what you try to achieve.
1. If you want to void the list (i.e. empty it of its contents), you can set its RowSource property to an empty string ("").
2. If you want to reset it to what it was when the form was open, you can store its RowSource property in a member variable when the form is open and reassign the value of this varianble to the RowSource property of the list later on.
In the form class module:
Option Compare Database
Private m_strListRowSource As String
Private Sub Command_VoidList_Click()
' Delete all rows from the list.
Me.List0.RowSource = ""
Private Sub Command_ResetList_Click()
' Restore the content of the list in the state
' it was when the form was open.
Me.List0.RowSource = m_strListRowSource
Private Sub Form_Open(Cancel As Integer)
' Store the RowSource property of the list
' in the m_strListRowSource member variable.
m_strListRowSource = Me.List0.RowSource
Ok, I havent tried your suggestions yet, but before I do I will try to explain the issue.
The 3 listboxes each show 1)Users, 2)Visits, 3)Activities.
If I select a User eg usr001 (lstusers), this users visits are displayed in lstvisits. This is working fine.
Next I want view the activities taken place during this visit. So I click on a visit (lstvisits) and this shows the activities for that visit (lstactivities). This also works fine.
To view a different user (eg usr002) I go back to lstusers, select usr002 and those visits are displayed in lstvisits. But the results in lstactivities are still those from the previous user (usr001).
The third list box (lstactivities) is not emptying/clearing/ when a different user from the first listbox (lstusers) is selected. It still shows the other users activities until the second listbox (lstvisits) is selected.
Ok. What code runs on the AfterUpdate event of the first and second list? Does the code in the the AfterUpdate event of the first list changes the RowSource property of the third list? If not, the problem may be there.