View Single Post
 
Old 09-21-2016, 06:30 AM
Charles Kenyon Charles Kenyon is offline Windows 8 Office 2013
Moderator
 
Join Date: Mar 2012
Location: Sun Prairie, Wisconsin
Posts: 9,533
Charles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant future
Default

Go to the tutorial. Do not try to reconstruct that field!
The tutorial is a Word document. You can take a field in that document, copy it, and paste it into your own document. Then you can change it to suit.

For instance: CreateDate -> SaveDate
Delay = 14 -> Delay = 21

Yes, all curly braces must be inserted using Ctrl+F9, in pairs. Reconstructing that field manually is virtually impossible. Also, spaces added to make it more readable may change how the field behaves.

If you do not want to use Paul Edstein's tutorial (which you should), you can download an Add-In that will create a field for you from this site:
http://web.archive.org/web/201110310...ed%20Dates.htm That was the original source of the field on my web page.

Paul spent a great deal of effort and used expertise few possess to write his tutorial. I would advise using it. You will tear your hair out trying to write fields that are freely available in the tutorial.Date Calculation Tutorial

If you just want the field I posted above, go to my page Calculated Dates in Microsoft Word using Fields or vba and use the link on that page to download a file that contains that field. I recommend using Paul's instead, though. His tutorial includes a good discussion on how to copy and paste them as well as about formatting differences.

Once you have downloaded Paul's tutorial, you can experiment and learn how these fields work if you want. Here are some of his other tutorials on fields:
Microsoft Word Field Maths Tutorial
Word Fields and Relative Paths to External Files

This stuff is neither straightforward nor simple. It does follow rules but discovering those rules can be a painful process. I feel happy just being able to use a field someone else has constructed and manipulate it to suit my needs.

If needed, there are macros available online (Graham's site) that convert field codes to text and back. Again, because of spacing issues, those would not work with the field I posted above.

www.gmayor.com/export_field.htm
www.gmayor.com/export_field.htm#TextToField
Reply With Quote