When a text file is opened in Word carriage returns are treated as paragraph markers. Hence ^p. ^ means a special character is next and p means that it is the end of a paragraph.
Note that line feeds are represented by ^l (carat + lowercase L), which might look the same in your document.
zhshqzyc
ASKER
My case is a little complex. Please see the attached samples.
VBA needed?
This is changing from a simple question to a project.
Also it's not easy to understand what you are trying to do.
You have some underlined paragraphs with text beginning 'TITLE'. After that you have some other paragraphs, alternating between short paragraphs, ending with a colon, and longer paragraphs which don't. There is also an empty paragraph after this set.
Assuming that you have taken our previous advice on board, can you now please explain where you are having problems?
The previous advice is helpful. But it removed all carriage return. What I want is to keep one carriage return between short paragraphs.
I used replace all to cause the issue. Probably I have to replace one by one.
Paul Sauvé
Original question (ID: 27037232, Author: zhshqzyc): I have a lot Carriage return in a file, how to replace them with empty quickly?
Now I delete them manually.
I agree - esentially, the question (ID: 35757264, Author: zhshqzyc) has nothing to do with replacing carriage returns.
Paul Sauvé
If you look at the test.doc file, you are trying to insert new paragraphs at what seems random places in your document. This can only be done manually.
Find: ^p
Replace: (space or nothing)