Hello,
Please help me. What is wrong with these statements. Every time it gives type mismatch error. In tblUser, Username is a short text field and lngUserID is a public variable defined as long integer.
Please help me. What is wrong with these statements. Every time it gives type mismatch error. In tblUser, Username is a short text field and lngUserID is a public variable defined as long integer.
Code:
Dim strUserName As String
strUserName = Nz(DLookup("UserName", "tblUser", "UserID ='" & lngUserID & "'"), "Untitled")