In access when datatype is numbers how do i get spaces inbetween .

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

When in access in design view and i change the data type to Numbers and then
i go into DataSheet View how do i get spaces inbetween the numbers that i
have entered and how can i put 0's before each number without it deleting the
0?
 
Asta said:
When in access in design view and i change the data type to Numbers
and then i go into DataSheet View how do i get spaces inbetween the
numbers that i have entered and how can i put 0's before each number
without it deleting the 0?

Spaces are not numbers. 120 45 is not a number it is two numbers.

Displaying numbers with leading zeros is not difficult it is a format
property. You have to set it in the reports or forms you want to display
the data that way.

It sounds to me like this should be text not number type. If you want
variable formatting you want text. You can't add, subtract etc. text, but
you can't add 10 89 + 4548 1 and get anything.
 
You can't store either spaces or leading zeros in a numeric field. You can,
however, *display* the number with spaces and leading zeros, in queries,
forms and reports. For example ...

? format(123, "000 00")
001 23

Check out the format property and the Format function in the help file and
the online documentation for more details.
 
Back
Top