A
Ashby
Try this code on the "ON KEY PRESS" event of the field.
If KeyAscii = 34 Then
MsgBox "Quotation marks are not allowed"
SendKeys "{BS}"
End If
The 34 represents the Ascii number for a quotation mark.
The sendkeys statement forces a backspace which removes
the quotation mark that was typed.
If KeyAscii = 34 Then
MsgBox "Quotation marks are not allowed"
SendKeys "{BS}"
End If
The 34 represents the Ascii number for a quotation mark.
The sendkeys statement forces a backspace which removes
the quotation mark that was typed.