Formatting

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

Guest

Would anybody know of a code I could use in the format section of a field
wihich will cause only the first letter of seperate words to be in uppercase.

e.g.
A name in the format of John Smith?
 
Would anybody know of a code I could use in the format section of a field
wihich will cause only the first letter of seperate words to be in uppercase.

e.g.
A name in the format of John Smith?

Using a form for data entry, code the control's AfterUpdate event:
[FieldName] =strConv([FieldName],3)

Note: This will not properly capitalize names that should have more
than one capital letter, i.e. McDonald, O'Brien, Smith-Jones, ABC
Vending Co. etc. nor properly spell words that should not be
capitalized, van den Steen, etc.


If the names are already in the database, use an unbound control to
display them:
=StrConv([FieldName],3)
 
hanks for this, can you explain this one a bit further I am getting to grips
with Access, does this invove creating a macro or writing code?

fredg said:
Would anybody know of a code I could use in the format section of a field
wihich will cause only the first letter of seperate words to be in uppercase.

e.g.
A name in the format of John Smith?

Using a form for data entry, code the control's AfterUpdate event:
[FieldName] =strConv([FieldName],3)

Note: This will not properly capitalize names that should have more
than one capital letter, i.e. McDonald, O'Brien, Smith-Jones, ABC
Vending Co. etc. nor properly spell words that should not be
capitalized, van den Steen, etc.


If the names are already in the database, use an unbound control to
display them:
=StrConv([FieldName],3)
 
Back
Top