?
=?windows-1250?Q?Vladim=EDr_Cvajniga?=
Public Function editMemo()
On Error Resume Next
With Screen.ActiveControl
.SelStart = 0
.SelLength = 0
End With
End Function
I'd like to use this function to prevent accidental deletion of memo (text
box) content when user sets focus to an appropriate control, eg.
txtMemo.OnSetFocus is set to =editMemo().
But I'm experiencing something that I don't understand: when a user presses
Enter on a preceding control Access doesn't clear the key buffer and adds a
CRLF (blank line) to the beginning of the txtMemo control content
(txtMemo.Text).
I must be doing something wrong...
TIA
Vlado
On Error Resume Next
With Screen.ActiveControl
.SelStart = 0
.SelLength = 0
End With
End Function
I'd like to use this function to prevent accidental deletion of memo (text
box) content when user sets focus to an appropriate control, eg.
txtMemo.OnSetFocus is set to =editMemo().
But I'm experiencing something that I don't understand: when a user presses
Enter on a preceding control Access doesn't clear the key buffer and adds a
CRLF (blank line) to the beginning of the txtMemo control content
(txtMemo.Text).
I must be doing something wrong...
TIA
Vlado