Re: Field to Upper Case
- From: John Vinson <jvinson@xxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 22 Jun 2005 19:07:34 -0600
On Wed, 22 Jun 2005 15:15:01 -0700, Leslie
<Leslie@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote:
>I would like to define a text field in a table to convert anything typed into
>it to Upper Case. Can I do this at the Table-Field level, or do I need to do
>this at the Forms-Update database level? (e.g. "UUUUU" to force to upper
>case in the format field on the table definition -- sorry if I'm old-school).
Well... you're also unkind to users if the fields are actually free
text such as names or addresses. All upper case is HARD TO READ.
>I would prefer that the field auto-format any text entered to upper case. I
>couldn't find anything in the help files.
You can use a table format of
>
just the greater-than sign - to *display* the data in upper case.
However, this does not change the way the data is stored, just how
it's displayed. To actually be able to type "foo" and have "FOO"
stored in the table, you must use a Form for data entry (since tables
don't have usable events). You can put the following code in the
textbox's AfterUpdate event:
Private Sub textboxname_AfterUpdate()
Me!textboxname = UCase(Me!textboxname)
End Sub
using your actual control name of course.
>Simple question in Office Access 2003, why do not the Text fields have any
>drop-down formatting options, like the numeric, date, etc.?
Form Textboxes do. Right mouseclick the textbox on the form and view
its Properties; click the Format tab. There's a Format property for
which you can use a dropdown providing many options, or enter your own
custom format.
John W. Vinson[MVP]
.
- Follow-Ups:
- Re: Field to Upper Case
- From: Leslie
- Re: Field to Upper Case
- References:
- Field to Upper Case
- From: Leslie
- Field to Upper Case
- Prev by Date: Re: query upon query
- Next by Date: How do I create name and Address list for printing
- Previous by thread: Re: Field to Upper Case
- Next by thread: Re: Field to Upper Case
- Index(es):
Relevant Pages
|