Copy link to clipboard
Copied
So I have a long document consisting of company names and booth numbers ordered like this:
company name
booth number
company name
booth number
etc.
The company name and booth number lines are separate paragraph styles. I want to combine the lines like this
company name booth number
company name booth number
I'd put either a tab or an em space between the name and booth number, but they'd be on one line together.
Is there a GREP method of doing that? I can't think of an obvious way to go about it. Ideally, I'd change the booth number into a character style so it would still have a different look when it becomes part of the company name paragraph style.
Thanks, Phyllis
Step 1. Find what:\r(?=\d{4})
Change to:\t
Step 2. In your 'Company Name' Para style include this GREP:
Apply Style: [your character style for booth number]
To Text:\t\K\d{4}
Your ParaStyle for booth number is obsolete now.
Copy link to clipboard
Copied
Forgot to mention: The booth number line consists of a number only (4 digits), no text.
Copy link to clipboard
Copied
Step 1. Find what:\r(?=\d{4})
Change to:\t
Step 2. In your 'Company Name' Para style include this GREP:
Apply Style: [your character style for booth number]
To Text:\t\K\d{4}
Your ParaStyle for booth number is obsolete now.
Copy link to clipboard
Copied
Wow. I guess that was way way way over my head, but it worked perfectly. Many thanks!!! That saves me tons of work.
Much appreciated.
Thanks, Phyllis
Copy link to clipboard
Copied
You're most welcome.