Formatting

T

TURNIP

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?
 
F

fredg

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)
 
T

TURNIP

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)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top