J
Jean-Paul
Hi,
I have a form with 2 listboxes.
the second one should be based upon the first one, so, if I go to the
next value in the first listbox, the second one should change too.
I wrote this code:
Private Sub Keuzelijst0_Click()
Dim sql As String
sql = "SELECT Sub_doel.Hoofddoel, Sub_doel.Sub_doel,
Sub_doel.Omschrijving FROM Sub_doel WHERE Sub_doel.Hoofddoel= " &
Forms!Doelstellingen!Keuzelijst0 & " ORDER BY Sub_doel.Sub_doel;"
Me!Keuzelijst2.RowSource = sql
Me!Keuzelijst2.Requery
End Sub
But, when nothing changes when I change Keuzelijst0
(finally, more listboxes chould change when the first one is changed)
What am I doing wrong?
Thanks
I have a form with 2 listboxes.
the second one should be based upon the first one, so, if I go to the
next value in the first listbox, the second one should change too.
I wrote this code:
Private Sub Keuzelijst0_Click()
Dim sql As String
sql = "SELECT Sub_doel.Hoofddoel, Sub_doel.Sub_doel,
Sub_doel.Omschrijving FROM Sub_doel WHERE Sub_doel.Hoofddoel= " &
Forms!Doelstellingen!Keuzelijst0 & " ORDER BY Sub_doel.Sub_doel;"
Me!Keuzelijst2.RowSource = sql
Me!Keuzelijst2.Requery
End Sub
But, when nothing changes when I change Keuzelijst0
(finally, more listboxes chould change when the first one is changed)
What am I doing wrong?
Thanks