Script to change font of all unicode characters above standard English

J

Joe

I have a Word document of mixed English and Unicode Greek, including
polytonic Greek characters in the extended range. Right now, the whole
document is set to Times New Roman, but the extended Greek characters
are being font-substituted. I'd like to have a VB macro that will
change all characters in a selection above a certain Unicode range to a
different font.
I'm using Word 2004 Mac if that's relevant.
Help?
 
J

Jezebel

Under Windows, you iterate the characters and use AscW() to get the value:
if greater than 127, you've got a Unicode value. Sadly, to quote the
documentation, --

Visual Basic for the Macintosh does not support Unicode strings. Therefore,
AscW(n) cannot return all Unicode characters for n values in the range of
128 - 65,535, as it does in the Windows environment. Instead, AscW(n)
attempts a "best guess" for Unicode values n greater than 127. Therefore,
you should not use AscW in the Macintosh environment.
 
J

Joe

Well, that's not good. Does it work at all? All I need to do is find
every word that contains at least one character over 127 and change its
style or font.
 

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