About the Filter Table Method

Hi.
I have

  • Main Form (MF) with ListBox linked to a Filter Table (FT).
  • Sub Form linked to the MF by a SELECT […] :parameter linked to the
    SELECT parameter FROM FT WHERE (the only row).
  • Sub sub Form source = a table, linked to the SF.

All works fine and auto updates via Status Changed of list box:

[...]
    LB.commit() ‘ the list box
    SFC.reload ‘ the sub form
End Sub

But when these forms opens up, of course are displayed the last selected records, as parameter is stored in the FT.
So I want to clear the FT when closing the forms, so nothing shows up on opening before selection in the LB.
Tried the MF events

  • Before unloading
  • When unlosding

but code doesn’t run.

Sub LimparFT(Evt As Object)
    Dim MF As Object, Stmt As Object
    Dim sSQL As String
    MF = Evt.Source
    print "funcionando!"
End Sub

Thanks in advance!