Making Sure Username and Password Aren’t Empty
Now here is the code you looking for. Just know that Me.txtUserID refers to
as control box where users enter their username, and Me.txtPW is textbox control
'check for value in user UserName
If Nz(Me.txtUserID.Value) = "" Then
MsgBox "You must enter a User ID", vbOKOnly + vbCritical, "No User ID Entered"
'check for value in user pw
If Nz(Me.txtPW.Value) = "" Then
MsgBox "You must enter your Password", vbOKOnly + vbCritical, "No Password Entered"
(If you don’t know how to attach this code to ENTER button, please follow these step-by-step tutorial )
Next : Making Sure to check for update