Finding special characters inserted as Asc(40) or (63)

  • Thread starter Charlie''s Word VBA questions
  • Start date
C

Charlie''s Word VBA questions

I need to find inserted special/symbol characters entered as "(normal text)"
and Asc(40) or (63). I have seen many great ideas and macros on the subject,
but all of them seem to assume that you know what font and/or character to
look for.
The problem is that it is not known what fonts or characters are in the
document. I have a macro that loops through all fonts to find fonts in the
document. I also have a macro that searches each character and determines
whether it is a special character and, if so, its font name. However, in a
large document (300 to 500 pages), this can take forever to examine every
character.
I am hoping that I can do a Selection.Find.Execute. I can loop thru each
font in the document to do the search. If a character does not exist, that's
OK. If there is any inserted symbol (as Asc(40/63)), Find would take me to
it and I can then find the return the symbol. Bottom line is that it is not
known what characters, if any, are in the document.
Any suggestions will be really appreciated.
Charlie
 
J

Jonathan West

"Charlie''s Word VBA questions"
I need to find inserted special/symbol characters entered as "(normal
text)"
and Asc(40) or (63). I have seen many great ideas and macros on the
subject,
but all of them seem to assume that you know what font and/or character to
look for.
The problem is that it is not known what fonts or characters are in the
document. I have a macro that loops through all fonts to find fonts in
the
document. I also have a macro that searches each character and determines
whether it is a special character and, if so, its font name. However, in
a
large document (300 to 500 pages), this can take forever to examine every
character.
I am hoping that I can do a Selection.Find.Execute. I can loop thru each
font in the document to do the search. If a character does not exist,
that's
OK. If there is any inserted symbol (as Asc(40/63)), Find would take me
to
it and I can then find the return the symbol. Bottom line is that it is
not
known what characters, if any, are in the document.
Any suggestions will be really appreciated.
Charlie

This article should help

Finding and replacing symbols
http://www.word.mvps.org/FAQs/MacrosVBA/FindReplaceSymbols.htm


--
Regards
Jonathan West - Word MVP
www.intelligentdocuments.co.uk
Please reply to the newsgroup
Keep your VBA code safe, sign the ClassicVB petition www.classicvb.org
 

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