How do I capitalize?

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

Guest

I want to capitalize the first letter of the last name in my phone directory
access database
 
You can use an Input Mask to format the entry when the user adds a record or
a format if the records are already in the table and you wish to format the
output, but keep in mind that this will not work in a lot of cases.

McMillan would become Mcmillan
De la Cruz would become De la cruz


etc.

I would recommend making your users do it right, not forcing it. I don't
think I've ever typed a name in my life where I did not instinctively hit
the shift key to capitalize the first letter. It's just second nature.

Rick B
 
Create a new module:

Option Compare Database

Function properau(field As Control)
field = StrConv([field], vbProperCase)

End Function

Save module and call it lets say proper.

If you have created a form based on your table and lets
say the fieldname you want to capitalize the first letter
of is named LastName.In the properties of that field go to
the after_update and type in the following:

=properau([LastName])

regardless if you use uppercase or lowercase, after you
press enter to move to the next field, the first letter of
LastName will capitalise
 
Back
Top