J
JC
I have made the following changes to my code. I am trying to update
recordset from a list box with the values the user clicks. It worked,
but I want to add another criteria to it. I would like to feed a text
box entry to filter the recordset. Please see below, the part "...I
cannot get to work" is the one I am wondering about. Can I add "AND"
logic to filter the recorset?
Private Sub lstStudentInfo_AfterUpdate()
' Find the record that matches the control.
Dim rs As Object
Set rs = Me.Recordset.Clone
rs.FindFirst "[ID] = " & Str(Nz(Me![lstStudentInfo], 0))
&
-This is the part I cannot get to work
"And " & [adTermCode] = [Forms]![frmData]![txtTerm]
If Not rs.EOF Then Me.Bookmark = rs.Bookmark
End Sub
Thank you for your help,
Justin
recordset from a list box with the values the user clicks. It worked,
but I want to add another criteria to it. I would like to feed a text
box entry to filter the recordset. Please see below, the part "...I
cannot get to work" is the one I am wondering about. Can I add "AND"
logic to filter the recorset?
Private Sub lstStudentInfo_AfterUpdate()
' Find the record that matches the control.
Dim rs As Object
Set rs = Me.Recordset.Clone
rs.FindFirst "[ID] = " & Str(Nz(Me![lstStudentInfo], 0))
&
-This is the part I cannot get to work
"And " & [adTermCode] = [Forms]![frmData]![txtTerm]
If Not rs.EOF Then Me.Bookmark = rs.Bookmark
End Sub
Thank you for your help,
Justin