Steven,
This code works. BUT, 1) I don't want to use PUBLIC variables. I can create another class property, but it's too complicated.
2) I also want to allow only digits, no characters.
>
>Here is code that will only let 5 characters be entered into each line of the edit box. Again ekp is only a variable. It's value needs to be set to zero in the init event of the editbox.
>
>If nKeyCode = 13 Then
>If ekp < 4 Then
> MessageBox("Must Be five characters")
> NoDefault
> Else
> ekp = 0
> EndIf
>Else
> If ekp = 4 Then
> KEYBOARD'{Enter}'
> Else
> ekp = ekp + 1
> EndIf
>EndIf
If it's not broken, fix it until it is.
My Blog