Solved Military time entry (1 Viewer)

PaquettePaul

Member
Local time
Today, 02:58
Joined
Mar 28, 2022
Messages
107
So, I decided to change the database for my wheels up and down times from date fields to 4 character fields. I am using the routine that arnelgp provided for time validation with some modifications.

A statement is in there to determine if non numeric characters exist. The issue is that the Val(txtField) function returns a 0 if a non numeric character is found; however, the plus sign, negative, sign, and decimal place are recognized as being ok. Obviously, those special characters are not ok in a time field.

Does anyone know any easy method of detecting those characters as well?
 

CJ_London

Super Moderator
Staff member
Local time
Today, 07:58
Joined
Feb 19, 2013
Messages
16,612
Don’t know what arnel provided but if using one of the key functions you should be able to exclude those characters
 

Users who are viewing this thread

Top Bottom