Just a comment. It's important to understand that when you use an Input
Mask, it usually only changes how the data appears in the text box, not
how it's stored. While it may appear that your field holds 1234.56.78.90,
by default it actually only holds the value 1234567890. If that's the
case, if you were to have a query that prompted the user to enter a
criteria for that field, they'd have to enter 1234567890, not
1234.56.78.90.
You can override that behaviour by using 0 as the second parmater of
the
InputMask. In other words, if you use an InputMask of 0000.00.00.00;0 then
what gets stored in the field will be 1234.56.78.90, and to match it in a
query you'd actually specify 1234.56.78.90.
Perhaps that's what Al was trying to accomplish by using "N" as the second
parameter, but it must be 0.
--
Doug Steele, Microsoft Access MVP
(no private e-mails, please)
Ricter,
Try an InputMask of....
000.00.00.00;0;"N"
The user would enter 10 digits with no periods, but the digits and
periods would be stored in the table.
OR
Without an InputMask, the user would enter ten digits into the
field,
(ex. [10Digs]) and then on the AfterUpdate event...
[10Digs] =Left([10Digs],4) & "." & Mid([10Digs],5,2) & "." &
Mid([10Digs],7,2) & "." & Right([10Digs],2)
The InputMask is the best solution, as it "requires" exactly 10
digits... no more, no less. Less chance for entry errors.
--
hth
Al Camp
Candia Computer Consulting - Candia NH
http://home.comcast.net/~cccsolutions
I would like to set up a form object (text box I imagine), such that when
a
user enters 10 straight numerals, it is written to the table in the
format
xxxx.xx.xx.xx
That is, I need the periods inserted, in those postions. How could this
be
done?
Tariff codes, in case you're curious. : )
Tia