Article ID: 138499
Article Last Modified on 2/11/2000
IF nKeyCode=13 OR nKeyCode=9 && test for ENTER or TAB
THISFORM.numb=0 && and reset numb
ELSE
IF !(nkeyCode=127 OR ; && BACKSPACE
nkeyCode=7 OR ; && DELETE
nkeyCode=6 OR ; && END key
nkeyCode=19 OR ; && LEFT ARROW
nkeyCode=4 OR ; && RIGHT ARROW
nkeyCode=1) && HOME key
THISFORM.numb=THISFORM.numb+1 && if not one of the above increment
IF THISFORM.numb=4 && When 4 characters have been entered
THISFORM.numb=0 && reset numb to zero and flash a message
?? CHR(7) && ring the bell
=MESSAGEBOX("Enter only 3 characters")
NODEFAULT && do not enter the character typed.
ENDIF
ENDIF
ENDIF
Additional query words: VFoxWin mask format
Keywords: KB138499