View Single Post
  #7   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Graham Mayor Graham Mayor is offline
external usenet poster
 
Posts: 19,312
Default Problem Maintaing Excel Format after Mail Merge

DDE is at best a flaky method of connection to a data source which is the
reason it was abandoned as the default from Word 2002. Ultimately it would
be better to configure your data source properly to avoid the problem in the
first place, or to use conditional fields to ensure that the correct data is
applied - see also http://www.gmayor.com/formatting_word_fields.htm

--

Graham Mayor - Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org



Mike wrote:
Dear macropod,

Haven't try this yet, but tried the DDE method suggested by Doug
Robbins. It worked, but have some problems if the files are stored in
the server.

Anyway, thanks for your suggestion.

Regards,
Mike

"macropod" wrote:

Hi Mike,

The fact that there are different kinds of data in the fields
doesn't prevent formatting switches being used. At most you'll need
an IF test. For example: {IF{MERGEFIELD Data \@ "dd-MM-yy"}=
"??-??-??" {MERGEFIELD Data \@ "dd-MM-yy"} {MERGEFIELD Data \#
",0.00"}}

Note: The field brace pairs (ie '{ }') for the above example are
created via Ctrl-F9 - you can't simply type them or copy & paste
them from this message.

--
Cheers
macropod
[MVP - Microsoft Word]


"Mike" wrote in message
...
How do I keep the display result in Mail Merge to follow exactly
the format set in the Excel file?

I cannot use the format switches due to the same field in the excel
file contains multiple format, ie. the same field contains data
like date and numbers, i need the display result in Word to show
both dates and numbers.