StarScream
Technical User
I have a Unbound Text Box on a form that a user can type in a message and when they hit enter, the message is transferred to a Bound Text Box that adds Date/Time/User stamp and displays the whole thing.
However, every time I input text twice (basically hit enter twice), it automatically jumps to the next record.
What I wanted was to create an Events Log. I wanted every time someone typed anything into the unbound box, that would create a new record. Instead, it keeps updating the same record -- not what I wanted, but it achieves the same effect.
Can anyone explain or help me turn off the Enter Twice Phenomena ? It seems to result from playing with the Tab Stop: Yes/No. When I set it to Yes, I lose the focus on the unbound text box (it highlights all the text in the bound text box). When I set it to No, the focus stays in the unbound text box, but it keeps skipping to the next record after every two entries.
Help!
However, every time I input text twice (basically hit enter twice), it automatically jumps to the next record.
Code:
Private Sub Text0_LostFocus()
Me![DateTimeStamp] = Now()
Me![Note] = Me![Note] & vbCrLf & vbCrLf & Text0 & " [" & Environ$("username") & " -- " & Me![DateTimeStamp] & "]"
Me![Text0] = ""
Me![Note].Requery
Me![Text0].SetFocus
End Sub
What I wanted was to create an Events Log. I wanted every time someone typed anything into the unbound box, that would create a new record. Instead, it keeps updating the same record -- not what I wanted, but it achieves the same effect.
Can anyone explain or help me turn off the Enter Twice Phenomena ? It seems to result from playing with the Tab Stop: Yes/No. When I set it to Yes, I lose the focus on the unbound text box (it highlights all the text in the bound text box). When I set it to No, the focus stays in the unbound text box, but it keeps skipping to the next record after every two entries.
Help!