Find and Replace

G

Guest

Using Word 2003 on CP platform. I'm trying to edit a large document which is
being converted from another software to Word. There are lines of control
commmands that I need to delete. Fortunately, each line begins with the
character #.

I don't see a way of having the find and replace feature search for commands
beginning with # and deleting the entire line. Can someone help?
 
L

Larry

In the Find What box put this:
(^13)#[!^13]{1,}^13

In the Replace With box put this:
\1

And check the Use Wildcards feature.

Then you will have to run Replace All twice (to get any lines with #
that are sequential to each other that are missed on the first pass).
Getting them all in one pass would require a macro and I'm trying to
keep this simple for you.

Larry
 
G

Guest

Evidently I didnot do the right thing. An example of the control line is:

#VERSE_COMMENTARY:Ex 4:20

Where the information after the colon changes.
 
G

Graham Mayor

A bigger sample than just the one line would be helpful (including the other
text you wish to keep); however wildcard seartch I posted earlier will find
this line *provided the line ends with a paragraph mark*

i.e

#*^13
replace with nothing

Did you check the wildcard check box?

--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP

My web site www.gmayor.com

<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top