Field numbering problem related to different French/English list separator

S

Stephen Boyd

I am trying to use field codes to avoid having different odd/even page
headers and footers.
The fields I'm using are
{IF {=MOD({PAGE} , 2 )} = 1 {PAGE}}, which gives the page number on an odd
page and nothing on an even page
and
{IF {=MOD({PAGE} , 2 )} = 0 {PAGE}}, which gives the page number on an even
page and nothing on an odd page
Using Word 97 (English UK version) on computers running Windows NT with
either English or French regional settings.
On the French computers these fields give a syntax error as it seems to want
a semicolon in place of the commas.
Is there any way of writing a field that works on both sets of computer, or
is there some other workaround?
 
J

Jean-Guy Marcil

Bonjour,

Dans son message, < Stephen Boyd > écrivait :
In this message, < Stephen Boyd > wrote:

|| I am trying to use field codes to avoid having different odd/even page
|| headers and footers.
|| The fields I'm using are
|| {IF {=MOD({PAGE} , 2 )} = 1 {PAGE}}, which gives the page number on an
odd
|| page and nothing on an even page
|| and
|| {IF {=MOD({PAGE} , 2 )} = 0 {PAGE}}, which gives the page number on an
even
|| page and nothing on an odd page
|| Using Word 97 (English UK version) on computers running Windows NT with
|| either English or French regional settings.
|| On the French computers these fields give a syntax error as it seems to
want
|| a semicolon in place of the commas.
|| Is there any way of writing a field that works on both sets of computer,
or
|| is there some other workaround?

The only way I can think of is to have a macro in the Document_New procedure
that would build the field code with the appropriate list separator. If you
wanted to be fancy you could also include the same procedure in the
Document_Open procedure so that the document would display the correct
information, even when transferred from a French to English computer.

In your procedure use
MsgBox Application.International(wdListSeparator)
to find out what the current list separator is.

Have never tried it, but it sounds like it would work!
The tricky part is to create the embedded fields programmatically. A
workaround would be to have two autotexts, a French and an English version,
then, depending on the result of your
Application.International(wdListSeparator)
test, insert the appropriate autotext

Good luck.

--
Salut!
_______________________________________
Jean-Guy Marcil - Word MVP
(e-mail address removed)
Word MVP site: http://www.word.mvps.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