I have tried this code in a textbox's interactive change event but focus goes to the next textbox :-( Reason I am going this route is because if the texbox is empty, user is allowed to modify.
IF this.Value<>cordate AND LEN(ALLTRIM(this.Value)) =5
this.setfocus
EndiF
"Build a man a fire, and he's warm for a day.
Set a man on fire, and he's warm for the rest of his life."