I have some company addresses in an excel - here is how one of the cells look like. The number of company addresses in any cell varies.
abc
United Kingdom
Main Phone: 1234567
Main Fax: 63273818
Other Phone: 53177188
dfr
China
Main Phone: 2345671
Main Fax: 632738188
rtg
United States
Main Phone: 2434571
Main Fax: 3278188
Other Phone: 31771988
What I want as a outcome is
abc
United Kingdom
dfr
China
rtg
United States
I have researched for this; however, could not find anything. I am trying to find a way to get the position of "Main" and the empty line and then delete the text in between. I tried with CHAR(10) & CHAR(13)
..but those did not work. Any help in this regard would be welcome. Many thanks.
P.S>> If anyone can suggest any VBA code to do work, that would be also useful. Many thanks.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…