concatenate name fields for display

jmlight

Registered User.
Local time
Today, 12:19
Joined
Feb 6, 2009
Messages
54
In my form, I have FirstName and LastName fields displayed. I would like to trim the spaces and have the two fields concatenate for display purposes.

I have tried going to the field Properties in Design View, and then attempted to make an expression something like:
firstname & " " & Lastname

All that shows up where the field should be is the word Error.

I'm sure there's a way to do this that trims the leading and trailing spaces and makes the name look like I typed them together.

Help?
 
As a textbox control source, try:

=Trim(firstname) & " " & Trim(Lastname)

Make sure no textbox or other control has either of those names.
 
Thanks Paul - that worked. I just had to make a "new" unbound text box instead of trying to make an expression out of an existing field.

At least I've got ONE thing right so far!
 
Yeah, the wizard will name the control the same as the field, and when you try to make an expression like that it gets confused. You could also have renamed the control.
 

Users who are viewing this thread

Back
Top Bottom