H
hollyylloh
I am using a Dlookup function to return a record from a table and then I
would like to set the value of a field in that record. I have:
Dim acctype as variant
acctype = Dlookup("[AccType]", "tblPermit", "[User] = Forms!frmSignin!user
and [Password] = Forms!frmSignin!password")
If acctype = "Writer" then
docmd.OpenForm "frmMain"
Forms!frmMain!cmdCompany.Enabled = True
' need help here to write a value to the table ?? Tables!tblPermit!Loggedin
= True
' for the user referenced in the Dlookup ??
End if
Perhaps me approach is all wrong? Should I be referencing a recordset?
Thanks for your help!
would like to set the value of a field in that record. I have:
Dim acctype as variant
acctype = Dlookup("[AccType]", "tblPermit", "[User] = Forms!frmSignin!user
and [Password] = Forms!frmSignin!password")
If acctype = "Writer" then
docmd.OpenForm "frmMain"
Forms!frmMain!cmdCompany.Enabled = True
' need help here to write a value to the table ?? Tables!tblPermit!Loggedin
= True
' for the user referenced in the Dlookup ??
End if
Perhaps me approach is all wrong? Should I be referencing a recordset?
Thanks for your help!