Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Mailmerge and Fax / January 2006

Tip: Looking for answers? Try searching our database.

Format the field of DATE

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
LS - 09 Jan 2006 11:02 GMT
I have a field of DATE in data source file entered as 051025 to mean yyMMdd.
How do I format the field in main document to show the date as 2005-10-25 or
2005/10/25 ?  Thanks.
Doug Robbins - Word MVP - 09 Jan 2006 12:49 GMT
I don't think that it is possible to do that using formatting switches on
the field.  This means that you would either have to do modify the data
source, or after executing the merge to a new document, do a wildcard Find
and Replace where you search for

([0-9]{2})([0-9]{2})([0-9]{2})

and replace that with

20\1/\2/\3

To learn about use a wildcard search, see the article "Finding and replacing
characters using wildcards" at:

http://www.word.mvps.org/FAQs/General/UsingWildcards.htm

Signature

Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

>I have a field of DATE in data source file entered as 051025 to mean
>yyMMdd. How do I format the field in main document to show the date as
>2005-10-25 or 2005/10/25 ?  Thanks.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.