Combine a contact name and company
Turn Ava Reed and Acme into Ava Reed — Acme for labels and lists.
What you'll make

The formula

| Number | Part | What it does | Result so far |
|---|---|---|---|
| 1 | TRIM(A8)="" | Checks whether the contact name is empty. | Not empty |
| 2 | TRIM(B8) | Shows the company alone when the name is empty. | Not used for row 8 |
| 3 | TRIM(A8) | The contact name, without stray spaces. | "Ava Reed" |
| 4 | IF(TRIM(B8)…) | Adds a long dash and the company, if there is one. | "Ava Reed — Acme" |
| 5 | IF( … ) | Picks the name, the company, or both joined. | "Ava Reed — Acme" |
Read it left to right. The dash appears only when both are there.
=IF(TRIM(A8)="",TRIM(B8),TRIM(A8)&IF(TRIM(B8)="",""," — "&TRIM(B8)))How to use it
Yellow bar at the top? Click Enable Editing.
- See it work. The Example tab shows 20 made-up names with the formula already in.
- Use your own names. Paste contact names into column A and companies into column B of the Template tab. Leave one empty if you don't have it.
- Move them into your letter. Copy the results. Then use Paste Special and choose Values.
Before you send
This makes a label, not a full name. Check each person still works at that company.
Route: Get names ready for the letter
Microsoft's help: IF function
OTHER ROUTES YOU MIGHT LIKE

Put a name and role on separate lines
Ava Reed + Treasurer → Ava Reed ¶ Treasurer
Get the template →
Make an attention line from a name
Ava Reed → Attn: Ava Reed
Get the template →
Make a care-of line from a name
Ava Reed → c/o Ava Reed
Get the template →
Fix "Dear ," when a first name is blank
(blank) → Dear colleague,
Take this route →