Validation for Decimal Numbers

ACM

Registered User.
Local time
Today, 05:23
Joined
Sep 18, 2009
Messages
13
I'm trying to create some sort of validation so when a person enters a decimal number in the 'Squad Number' field, rather than rounding it up to the nearest whole number, how can I send out some sort of validation message which states that the user has to enter a whole number?

Below's picture will give you an idea:

http://img688.imageshack.us/img688/7319/accessepl.jpg
 
I would recommend doing the validation in the BeforeUpdate event of a control on a form. It is more flexable and you can tailor your messages as you wish.
If Me.YourControlName.Value <> Int(Me.YourControlName.Value) Then
'-- The user entered a decimal value.
 

Users who are viewing this thread

Back
Top Bottom