Get a name after an Attn: label
Turn Attn: Ava Reed into Ava Reed for greetings and name lists.
Download Excel templateMicrosoft 365
What you'll make

The formula

| Number | Part | What it does | Result so far |
|---|---|---|---|
| 1 | TEXTAFTER(A8,"Attn:",1,1) | Takes what comes after Attn:, in any capitals. | " Ava Reed" |
| 2 | TRIM( … ) | Removes the space left at the start. | "Ava Reed" |
| 3 | TRIM(A8) | With no Attn: label, keeps the whole cell. | Not used for row 8 |
| 4 | IFERROR( … ) | Uses part 3 when there is no Attn: label. | "Ava Reed" |
Each bracket wraps the one above it, so Excel works from the inside out.
=IFERROR(TRIM(TEXTAFTER(A8,"Attn:",1,1)),TRIM(A8))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 attention lines into the green column of the Template tab. The names fill in by themselves.
- Move them into your letter. Copy the results. Then use Paste Special and choose Values.
Before you send
Attn: should come first in each cell. Anything typed before it is dropped, so check those rows by hand.
Route: Get names ready for the letter
Microsoft's help: TEXTAFTER function
OTHER ROUTES YOU MIGHT LIKE

Get a quoted display name from an email
"Ava Reed" <[email protected]> → Ava Reed
Get the template →
Separate a name from an em-dash role
Ava Reed — Treasurer → Ava Reed
Get the template →
Get a name before a parenthesized ID
Ava Reed (0027) → Ava Reed
Get the template →
Fix "Dear ," when a first name is blank
(blank) → Dear colleague,
Take this route →