#1
|
|||
|
|||
Default How to automatically Calculate number of days between two dates?
Hi guys! I have a possibly basic question....
I Have attached a word doc showing two date boxes. First box showing the starting day of a shift and the second is the last day of the shift. I'm hoping to automate the counting of the number of days worked. Is this easy to do? Unfortunately it has to be done in word or PDF and not excel. Would love any advice thanks in advance! |
#2
|
||||
|
||||
It is easy enough to do in Word - create a new document from the attached template and click in the 'Days' field. If you want PDF, save the resulting file as PDF.
__________________
Graham Mayor - MS MVP (Word) (2002-2019) Visit my web site for more programming tips and ready made processes www.gmayor.com |
#3
|
|||
|
|||
For much more on date fields, see Paul Edstein's document.
Microsoft Word Date Calculation Tutorial |
#4
|
|||
|
|||
Thanks Gmayor this worked a treat! The hilarious thing is that it worked on my person computer at home but my work computer has blocked ALL macros and I cannot even turn them on in settings/options. Arrgh!
|
#5
|
|||
|
|||
Quote:
It looks like its all kinda hopeless since my work organisation has blocked all macros. May need to go to Adobe acrobat instead =/ |
#6
|
|||
|
|||
You do not need to run macros to use that. Just copy and paste fields.
The macro is only needed if you need to change the date format. Do you do dates as October 24, 2019, or as 24 October 2019? |
#7
|
||||
|
||||
Adobe Acrobat isn't going to help. However Paul's Date Calculations document does have a solution on Page 10. It is a clever solution, if not as convenient to the user as content controls and macros, but it does still work and calculates the difference when you tab out of the end date field..
__________________
Graham Mayor - MS MVP (Word) (2002-2019) Visit my web site for more programming tips and ready made processes www.gmayor.com |
Thread Tools | |
Display Modes | |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Calculate amount of days per month from a given timerange | Yde1203 | Excel | 3 | 05-02-2019 08:13 PM |
Calculate number of days in a table from a specific date | tstolbert | Word | 2 | 06-25-2016 02:30 PM |
Formula To Calculate Countdown Days To Project Completion | Catherine | Project | 1 | 02-19-2014 11:15 AM |
Calculate difference by days and hours | alysolyman | Excel | 6 | 05-13-2013 02:19 AM |