Discussion:
Formating fields in mail merge
(too old to reply)
Tamir
2010-02-14 04:14:03 UTC
Permalink
Hi,
When doing a mail merge (using excel 2003 as my data base) I lose the comma
of the thousands. How can I format the mail merge field? Are there formating
switches?
Thank you,
Tamir
macropod
2010-02-14 04:58:24 UTC
Permalink
Hi Tamir,

To control number & currency formatting in Word, add a numeric picture switch to the mergefield. To do this:
. select the field;
. press Shift-F9 to reveal the field coding. It should look something like {MERGEFIELD MyData};
. edit the field so that you get {MERGEFIELD MyData \# $,0.00} (or whatever other numeric format you prefer - see below);
. position the cursor anywhere in this field and press F9 to update it;
. run your mailmerge.

Note: The '\# $,0.00' in the field is referred to as a numeric picture switch. Other possibilities include:
. \# 0 for rounded whole numbers
. \# ,0 for rounded whole numbers with a thousands separator
. \# ,0.00 for numbers accurate to two decimal places, with a thousands separator
. \# $,0 for rounded whole dollars with a thousands separator
. \# "$,0.00;($,0.00);'-'" for currency, with brackets around negative numbers and a hyphen for 0 values


The precision of the displayed value is controlled by the '0.00'. You can use anything from '0' to '0.000000000000000'.

If you use a final ';' in the formatting switch with nothing following, (eg \# "$,0.00;($,0.00);") zero values will be suppressed.
Note that this suppresses 0s resulting from empty fields and from fields containing 0s.
--
Cheers
macropod
[Microsoft MVP - Word]
Hi,
When doing a mail merge (using excel 2003 as my data base) I lose the comma of the thousands. How can I format the mail merge
field? Are there formating switches?
Thank you,
Tamir
Tamir
2010-02-14 05:18:53 UTC
Permalink
Thank you,
Works like a charm :-)
Tamir
Post by macropod
Hi Tamir,
To control number & currency formatting in Word, add a numeric picture
. select the field;
. press Shift-F9 to reveal the field coding. It should look something like
{MERGEFIELD MyData};
. edit the field so that you get {MERGEFIELD MyData \# $,0.00} (or
whatever other numeric format you prefer - see below);
. position the cursor anywhere in this field and press F9 to update it;
. run your mailmerge.
Note: The '\# $,0.00' in the field is referred to as a numeric picture
. \# 0 for rounded whole numbers
. \# ,0 for rounded whole numbers with a thousands separator
. \# ,0.00 for numbers accurate to two decimal places, with a thousands separator
. \# $,0 for rounded whole dollars with a thousands separator
. \# "$,0.00;($,0.00);'-'" for currency, with brackets around negative
numbers and a hyphen for 0 values
The precision of the displayed value is controlled by the '0.00'. You can
use anything from '0' to '0.000000000000000'.
If you use a final ';' in the formatting switch with nothing following,
(eg \# "$,0.00;($,0.00);") zero values will be suppressed. Note that this
suppresses 0s resulting from empty fields and from fields containing 0s.
--
Cheers
macropod
[Microsoft MVP - Word]
Post by Tamir
Hi,
When doing a mail merge (using excel 2003 as my data base) I lose the
comma of the thousands. How can I format the mail merge field? Are there
formating switches?
Thank you,
Tamir
unknown
2010-02-14 08:08:01 UTC
Permalink
עפ"י שמך אני מרשה לעצמי לצאת מנק' הנחה שאתה קורא גם עברית - ולכן אעצתי לך
לבדוק דרך נוספת, שלדעתי, הינה פשוטה מאד:
בגיליון ה'אקסל' - לצד הנתונים המספריים - פתח עמודת עזר והצג בה את המספרים
בעזרת הפונקציה: FIXED או: TAXT.
נניח שבתא A1 הקלדת: 123,456,789.45
בתא B1 הקלד: (2,Fixed(A1= [ה-2 מציין 2 ספרות עשרוניות]
או:
("##.#,#",Text(A1=
כעת - כל שנותר לך הוא להפנות את המיזוג לתאים אלה.
והמשך/י, נא, לקרוא את השורה הבאה:
***********
אם תגובתי עזרה לחץ/י, נא, על <כן> בפס האופקי התחתון!
***********
מיכאל אבידן
מנהל פורום "אופיס" ב"תפוז"
[Microsoft" Most Valuable Professional [MVP"
Post by Tamir
Thank you,
Works like a charm :-)
Tamir
Post by macropod
Hi Tamir,
To control number & currency formatting in Word, add a numeric picture
. select the field;
. press Shift-F9 to reveal the field coding. It should look something like
{MERGEFIELD MyData};
. edit the field so that you get {MERGEFIELD MyData \# $,0.00} (or
whatever other numeric format you prefer - see below);
. position the cursor anywhere in this field and press F9 to update it;
. run your mailmerge.
Note: The '\# $,0.00' in the field is referred to as a numeric picture
. \# 0 for rounded whole numbers
. \# ,0 for rounded whole numbers with a thousands separator
. \# ,0.00 for numbers accurate to two decimal places, with a thousands separator
. \# $,0 for rounded whole dollars with a thousands separator
. \# "$,0.00;($,0.00);'-'" for currency, with brackets around negative
numbers and a hyphen for 0 values
The precision of the displayed value is controlled by the '0.00'. You can
use anything from '0' to '0.000000000000000'.
If you use a final ';' in the formatting switch with nothing following,
(eg \# "$,0.00;($,0.00);") zero values will be suppressed. Note that this
suppresses 0s resulting from empty fields and from fields containing 0s.
--
Cheers
macropod
[Microsoft MVP - Word]
Post by Tamir
Hi,
When doing a mail merge (using excel 2003 as my data base) I lose the
comma of the thousands. How can I format the mail merge field? Are there
formating switches?
Thank you,
Tamir
.
dhaval
2010-02-14 14:40:42 UTC
Permalink
Post by Tamir
Hi,
When doing a mail merge (using excel 2003 as my data base) I lose th
comma
of the thousands. How can I format the mail merge field? Are ther
formating
switches?
Thank you,
Tamir
First you select all data than press shift plus f9 and select you ge
mail merge put a mouse cursor on data in press f9 and run mail merg
you got your answer


--
dhaval
macropod
2010-02-14 22:01:07 UTC
Permalink
Hi dhaval,

I don't think so. How is that supposed to correct the formatting?
--
Cheers
macropod
[Microsoft MVP - Word]
First you select all data than press shift plus f9 and select you get
mail merge put a mouse cursor on data in press f9 and run mail merge
you got your answer.
--
dhaval
Loading...