Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 03-05-2015, 04:02 AM
Dave1816uk Dave1816uk is offline Mail Merge date not working Windows 7 64bit Mail Merge date not working Office 2010 32bit
Novice
Mail Merge date not working
 
Join Date: Mar 2015
Posts: 2
Dave1816uk is on a distinguished road
Default Mail Merge date not working

Hi I have the following mail merge attached which I can't seem to get work correctly..or just don't understand.



The date field is set as 25/01/15 (Uk date)

I have set the delay date as 1 day (just testing)

but the date returned is Sunday, 22 September 2002

why is this? am I missing something?

Regards
Attached Images
File Type: png MailMergeQuery.png (13.4 KB, 16 views)
Reply With Quote
  #2  
Old 03-05-2015, 07:09 AM
gmayor's Avatar
gmayor gmayor is offline Mail Merge date not working Windows 7 64bit Mail Merge date not working Office 2010 32bit
Expert
 
Join Date: Aug 2014
Posts: 4,137
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

The construction from Paul's web site looks correct (and in any case should have been copied from his DateCalc document which you can download from my web site) and if the mergefield really does produce 25/01/15, and the regional date setting is UK English, the field construction will produce Monday, 26 January 2015

The implication therefore is that the mergefield doesn't produce 25/01/15. Have you tried the field without the delay? i.e. { MERGEFIELD RENEW_DATE } ?
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote
  #3  
Old 03-05-2015, 07:23 AM
Dave1816uk Dave1816uk is offline Mail Merge date not working Windows 7 64bit Mail Merge date not working Office 2010 32bit
Novice
Mail Merge date not working
 
Join Date: Mar 2015
Posts: 2
Dave1816uk is on a distinguished road
Default

Please see attached file checking the date is correctly Pulled and regional settings are correct to my knowledge.
Attached Images
File Type: png checks.png (23.6 KB, 16 views)
Reply With Quote
  #4  
Old 03-05-2015, 07:27 AM
gmayor's Avatar
gmayor gmayor is offline Mail Merge date not working Windows 7 64bit Mail Merge date not working Office 2010 32bit
Expert
 
Join Date: Aug 2014
Posts: 4,137
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

That looks OK, but what does

{ MERGEFIELD RENEW_DATE }

produce.

P.S. Forget that I see you have shown it at the top.
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote
  #5  
Old 03-05-2015, 07:40 AM
gmayor's Avatar
gmayor gmayor is offline Mail Merge date not working Windows 7 64bit Mail Merge date not working Office 2010 32bit
Expert
 
Join Date: Aug 2014
Posts: 4,137
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

Having mocked up your merge]



{MERGEFIELD RENEW_DATE}

{QUOTE
{SET Delay 1}
{SET a{=INT((14-{MERGEFIELD RENEW_DATE \@ M})/12)}}
{SET b{={MERGEFIELD RENEW_DATE \@ yyyy}+4800-a}}
{SET c{={MERGEFIELD RENEW_DATE \@ M}+12*a-3}}
{SET d{MERGEFIELD RENEW_DATE \@ d}}
{SET jd{=d+INT((153*c+2)/5)+365*b+INT(b/4)-INT(b/100)+INT(b/400)-32045+Delay}}
{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)}}
"{dd}-{mm}-{yy}" \@ "dddd, d MMMM yyyy"}

I get the following results

1/25/2015
Monday, 26 January 2015
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Mail merge to html not working CRMCathy Mail Merge 2 02-17-2015 07:59 PM
Mail Merge date not working Change Mail Merge Date Format from US to UK Evanaught Mail Merge 1 09-29-2013 08:02 PM
Mail Merge date not working mail merge treating CITY as DATE woody Mail Merge 6 01-30-2013 03:22 PM
Mail Merge date not working Date not transfering to mail merge correctly tonywatsonmail Mail Merge 1 07-01-2011 05:30 AM
Merge mail not working jdpowell@brazoriainet.com Mail Merge 1 07-25-2008 07:51 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 03:51 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft