I have a form with a VBA event. I have two text boxes with values that I have copied into strings. The records are stored in the values: val1, val2. They are strings with names that directly correspond to row entries in the the table.
The code I am trying to use to go to the record when the command button is pushed is:
Me.RecordsetClone.FindFirst ("[StudentName] = " & val2 And "[ClassName] = " & val1)
Me.Bookmark = Me.RecordsetClone.Bookmark
The table is called GradeDB. There are many fields in this table including two, one that says StudentName, one that says ClassName. When I debug the VBA it shows the correct text strings for val1 and val2. Even though both show up in the same row it throws an error message of - type mistmatch.
To boil the question down, I want to either be able to use gotorecord or findfirst with an expression containing two criteria.