Access 2007, geered toward Access 2000 version...
I have a cont. form (Room, NursingStation, patientname etc.)
that I want filtered based on a selection a user makes from a list box "lstnursingstation" in the header section. They would pick a Nursing Station (from a list of 7) and the records would show only say "1st floor" in that particular field.
I used this code on an afterupdate from the list box; Me.RecordSource = "SELECT MainTable.* FROM MainTable WHERE (((MainTable.NursingStation) = lstnursingstation)) ORDER BY MainTable.Room;" Something isn't right of course as it doesn't filter as I expect it to.
Any tips? Thanks, mvorous
I have a cont. form (Room, NursingStation, patientname etc.)
that I want filtered based on a selection a user makes from a list box "lstnursingstation" in the header section. They would pick a Nursing Station (from a list of 7) and the records would show only say "1st floor" in that particular field.
I used this code on an afterupdate from the list box; Me.RecordSource = "SELECT MainTable.* FROM MainTable WHERE (((MainTable.NursingStation) = lstnursingstation)) ORDER BY MainTable.Room;" Something isn't right of course as it doesn't filter as I expect it to.
Any tips? Thanks, mvorous