Find/Replace

R

rafa

Hello,

I want to select a whole string, based on some characters.
The next lines find the first letters of the word, but then I want the
full word.

Do you know how to do that?

Thank you very much indeed.

try
{
selection.Find.Execute(ref
sFirstLetters, ref missing, ref missing, ref missing, ref missing,
ref
missing, ref missing, ref missing, ref missing, ref missing,
ref
missing, ref missing, ref missing, ref missing, ref missing);

while (selection.Find.Found)
{
//Code to get full word
}
 
T

Tony Jollans

You should be able to look for firstletters followed by anything followed by
end-of-word if you set wildcards true.

I don't know the exact syntax but it is something like:

selection.Find.Execute(ref
sFirstLetters & "*>", ref missing, ref missing, ref boolean True, ref
missing,
ref
missing, ref missing, ref missing, ref missing, ref missing,
ref
missing, ref missing, ref missing, ref missing, ref missing)
 

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