D
don588765
I have problem writing the strCriteria declaration, the following is my code.
I guess my strCriteria declaration is incorrect, any help will be appreciated
Private Sub Form_Load()
Const strTableQueryName-“test_qryâ€
Dim db As DAO.Database,rst As DAO.Recordset
Set db=CurrentDb
Set rst = db.OpenReordset(strTableQueryName, dbOpenDyneaset, dbReadOnly)
TestFunction rst:=rst, strBooleanField:=â€uplinkâ€
End Sub
Sub TestFunction(rst As Recordset, strBooleanField As String)
……
…….
If srt.(strBooleanField) = false Then
strCriteria = (strbooleanField & “= falseâ€)
Else
…….
…….
rst.FindFirst strCriteria
……
……..
I guess my strCriteria declaration is incorrect, any help will be appreciated
Private Sub Form_Load()
Const strTableQueryName-“test_qryâ€
Dim db As DAO.Database,rst As DAO.Recordset
Set db=CurrentDb
Set rst = db.OpenReordset(strTableQueryName, dbOpenDyneaset, dbReadOnly)
TestFunction rst:=rst, strBooleanField:=â€uplinkâ€
End Sub
Sub TestFunction(rst As Recordset, strBooleanField As String)
……
…….
If srt.(strBooleanField) = false Then
strCriteria = (strbooleanField & “= falseâ€)
Else
…….
…….
rst.FindFirst strCriteria
……
……..