On 10 Mar 2007 10:02:43 -0800,
rz***@si.rr.com wrote:
I am looking for a technique with regards to the message displayed
when you enter text into a numeric field. I obviously get the "The
value entered isn't valid for this field" message how do I substitute
this message for my own? I have tried before update (if
notisnumeric(myfield.text), keydown. But I can not get it to wok,
thanks in advance!
Here's how you can find the correct error and show your own message
for any of the form level errors.
First code the Form's Error event:
MsgBox "Error#: " & DataErr ' Display the error number
Response = acDataErrDisplay ' Display Default message
Then open the form and intentionally make that error.
The message box will display the error number and the default error
message.
Next, go back to the error event and change that code to:
If DataErr = XXXX Then
Response = acDataErrContinue ' Don't display the default message
MsgBox "Please enter data in all required fields."
Else
MsgBox "Error#: " & DataErr
Response = acDataErrDisplay ' Display Default message
End If
where XXXX is the error number.
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail