# Make a column from a number of items in document

I have a number of email addresses like this:

"chinchin@gmail.com" <chinchin@gmail.com>, "Herman ." <Herman@hotmail.com>,
Tang Tang <tangtang@live.com>, "brown1@hotmail.co.uk"
<brown1@hotmail.co.uk>, " chipchip@hotmail.com"
<chipchip@hotmail.com>, "vivaviva@hotmail.com"


I need to make a list like this:

chinchin@gmail.com <chinchin@gmail.com>
Herman . <Herman@hotmail.com>,
Tang Tang <tangtang@live.com>
brown1@hotmail.co.uk <brown1@hotmail.co.uk>
chipchip@hotmail.com <chipchip@hotmail.com>
vivaviva@hotmail.com


I can get rid of the spaces and quotation etc but I need to know how to arrange the individual addresses in a column with one address per line. Thanks, Joe

Edit: formatting

edit retag close merge delete

Sort by » oldest newest most voted

You might want to do this on a copy in case there are variations not shown in your sample.

It looks like you want a return after each >, but you don't need that comma any more and there is also a space before the next name which should also be removed.

Open the Find & Replace dialog, Ctrl+H. In the Find field enter >, (that has a space following the comma), in the Replace field enter >\n. Make sure Regular Expressions is ticked. Click Replace All.

Want it as a table? Optional, not requested:

You could then replace [space]< with a tab if you wanted them to go into a table. In Find enter < (space then <), in Replace enter \t< (tab expression then <), make sure Regular Expressions is still ticked. Replace all

Once you have removed all the quotes you can turn it into a table by selecting it all, then clicking Table > Convert > Text to table

more

I’m not sure how to reply to you. I have searched. Since this is not an “Answer” to the original question, I’ll add this to “Comment”.

Thanks. That worked in most part.

"Herman ." Herman@hotmail.com,

Tang Tang tangtang@live.com

brown1@hotmail.co.uk

chipchip@hotmail.com

This saves a lot of work. However on the real document, which is quite long (94 lines), some of the lines were made into two lines. e.g.

"Herman ." on one line and Herman@hotmail.comon the next. "chinchin@gmail.com" on one line and chinchin@gmail.com on the next.

I can fix that. Now I just need to remove the quotes. Thanks for your help.

( 2020-11-16 13:45:15 +0100 )edit