View Single Post
 
Old 03-02-2013, 09:59 PM
macropod's Avatar
macropod macropod is offline Windows 7 64bit Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,467
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

As a follow-up:

An alternative approach, which doesn't require a change in the data connection method, is to use a field coded as:
Code:
{QUOTE
{SET jd{=2415019+{=INT({MERGEFIELD MyDate})}}}
{SET e{=INT((4*(jd+32044)+3)/146097)}}
{SET f{=jd+32044-INT(146097*e/4)}}
{SET g{=INT((4*f+3)/1461)}}
{SET h{=f-INT(1461*g/4)}}
{SET i{=INT((5*h+2)/153)}}
{SET dd{=h-INT((153*i+2)/5)+1}}
{SET mm{=i+3-12*INT(i/10)}}
{SET yy{=100*e+g-4800+INT(i/10)}}
"{mm}-{dd}-{yy}" \@ "MMMM d, yyyy"}
where 'MyDate' is your mailmerge field's name.


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


If you'd rather not encode the above by hand, you can download a macro to do it, from: http://www.gmayor.com/export_field.htm#TextToField
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote