Searching for a given number of (any) word?

F

Fewmitz

Example case:

....end of a paragraph. (example text text 12Aug09)

....end of a paragraph. (example text 11Aug09)

My plan was to put searches for 1-5 words into an Array and use them to
search for everything (all we do with each selection is color it), but when I
use <*> in the following manner:

(. )(<*> <*>
<[0123][0123456789][JFMASOND][aepuco][nbrylgpvc][0123456789][0123456789]>\))

(or something similar for three, four words, etc)

....it highlights large chunks of the document. Just doing a search for <*>
<*> properly returns any two words, but when applied above the functionality
doesn't seem to exist anymore.
 
F

Fewmitz

Thanks for the response, but that only boasted a moderate improvement. The
line I pasted in my OP would select a paragraph and then subsequent searches
would knock the beginning word of, one at a time.

The line you've sent will do the same thing, but knock it out by sentences.

macropod said:
Hi Fewmitz,

Try:
(. )(<*> <*> <[0-9]{1,2}[JFMASOND][aepuco][nbrylgpvc][0-9]{2}\))

--
Cheers
macropod
[Microsoft MVP - Word]


Fewmitz said:
Example case:

...end of a paragraph. (example text text 12Aug09)

...end of a paragraph. (example text 11Aug09)

My plan was to put searches for 1-5 words into an Array and use them to
search for everything (all we do with each selection is color it), but when I
use <*> in the following manner:

(. )(<*> <*>
<[0123][0123456789][JFMASOND][aepuco][nbrylgpvc][0123456789][0123456789]>\))

(or something similar for three, four words, etc)

...it highlights large chunks of the document. Just doing a search for <*>
<*> properly returns any two words, but when applied above the functionality
doesn't seem to exist anymore.
 
M

macropod

Hi Fewmitz,

Perhaps, then, you could explain what you're trying to achieve in more detail.

--
Cheers
macropod
[Microsoft MVP - Word]


Fewmitz said:
Thanks for the response, but that only boasted a moderate improvement. The
line I pasted in my OP would select a paragraph and then subsequent searches
would knock the beginning word of, one at a time.

The line you've sent will do the same thing, but knock it out by sentences.

macropod said:
Hi Fewmitz,

Try:
(. )(<*> <*> <[0-9]{1,2}[JFMASOND][aepuco][nbrylgpvc][0-9]{2}\))

--
Cheers
macropod
[Microsoft MVP - Word]


Fewmitz said:
Example case:

...end of a paragraph. (example text text 12Aug09)

...end of a paragraph. (example text 11Aug09)

My plan was to put searches for 1-5 words into an Array and use them to
search for everything (all we do with each selection is color it), but when I
use <*> in the following manner:

(. )(<*> <*>
<[0123][0123456789][JFMASOND][aepuco][nbrylgpvc][0123456789][0123456789]>\))

(or something similar for three, four words, etc)

...it highlights large chunks of the document. Just doing a search for <*>
<*> properly returns any two words, but when applied above the functionality
doesn't seem to exist anymore.
 
F

Fewmitz

Two sample cases would be something like this:

This is the end of an article. (Source 11Aug01)

This is the end of a second article. (Source Two 12Aug01)

Where "Source" and "Source Two" are the name of where the article was pulled
from, and as such can be any number of words.

I need the Find/Replace to select just the Source citation (the parenthesis
and the material contained in them). Everything I've tried so far will select
a bunch of text and STOP at the parenthesis (where the citation is the last
text selected)


macropod said:
Hi Fewmitz,

Perhaps, then, you could explain what you're trying to achieve in more detail.

--
Cheers
macropod
[Microsoft MVP - Word]


Fewmitz said:
Thanks for the response, but that only boasted a moderate improvement. The
line I pasted in my OP would select a paragraph and then subsequent searches
would knock the beginning word of, one at a time.

The line you've sent will do the same thing, but knock it out by sentences.

macropod said:
Hi Fewmitz,

Try:
(. )(<*> <*> <[0-9]{1,2}[JFMASOND][aepuco][nbrylgpvc][0-9]{2}\))

--
Cheers
macropod
[Microsoft MVP - Word]


Example case:

...end of a paragraph. (example text text 12Aug09)

...end of a paragraph. (example text 11Aug09)

My plan was to put searches for 1-5 words into an Array and use them to
search for everything (all we do with each selection is color it), but when I
use <*> in the following manner:

(. )(<*> <*>
<[0123][0123456789][JFMASOND][aepuco][nbrylgpvc][0123456789][0123456789]>\))

(or something similar for three, four words, etc)

...it highlights large chunks of the document. Just doing a search for <*>
<*> properly returns any two words, but when applied above the functionality
doesn't seem to exist anymore.
 
M

macropod

Hi Fewmitz,

I've been away for the past week or so. Hence the delay in replying.

Try:
\(*[0-9]{1,2}[JFMASOND][aepuco][nbrylgpvc][0-9]{2}\)

--
Cheers
macropod
[Microsoft MVP - Word]


Fewmitz said:
Two sample cases would be something like this:

This is the end of an article. (Source 11Aug01)

This is the end of a second article. (Source Two 12Aug01)

Where "Source" and "Source Two" are the name of where the article was pulled
from, and as such can be any number of words.

I need the Find/Replace to select just the Source citation (the parenthesis
and the material contained in them). Everything I've tried so far will select
a bunch of text and STOP at the parenthesis (where the citation is the last
text selected)


macropod said:
Hi Fewmitz,

Perhaps, then, you could explain what you're trying to achieve in more detail.

--
Cheers
macropod
[Microsoft MVP - Word]


Fewmitz said:
Thanks for the response, but that only boasted a moderate improvement. The
line I pasted in my OP would select a paragraph and then subsequent searches
would knock the beginning word of, one at a time.

The line you've sent will do the same thing, but knock it out by sentences.

:

Hi Fewmitz,

Try:
(. )(<*> <*> <[0-9]{1,2}[JFMASOND][aepuco][nbrylgpvc][0-9]{2}\))

--
Cheers
macropod
[Microsoft MVP - Word]


Example case:

...end of a paragraph. (example text text 12Aug09)

...end of a paragraph. (example text 11Aug09)

My plan was to put searches for 1-5 words into an Array and use them to
search for everything (all we do with each selection is color it), but when I
use <*> in the following manner:

(. )(<*> <*>
<[0123][0123456789][JFMASOND][aepuco][nbrylgpvc][0123456789][0123456789]>\))

(or something similar for three, four words, etc)

...it highlights large chunks of the document. Just doing a search for <*>
<*> properly returns any two words, but when applied above the functionality
doesn't seem to exist anymore.
 

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