Default values in a table.

  • Thread starter Thread starter Jason B
  • Start date Start date
J

Jason B

When I enter a figure into a field in a table, I want it
to be a set number of digits long. If the number entered
does not meet the criteria, then I want access to add two
zeros to the beginning of the number to meet the criteria
required.
Criteria required is 7 digits.
Example. 0154672 - Meets criteria
25439 - does not meet criteria so access changes
the number to 0025439.

Many thanks in advance.
 
If you just want to display all numbers as 7 digits, set the Format property
of the text box to:
0000000

If you want to require the user enters 7 digits, and leading zeros are not
allowed, set a Validation Rule on the field of:
Is Null Or Between 1000000 And 9999999


If the digits are significant (e.g. 1 is different from 01), use a Text
field instead of a Number field.
 
Back
Top