Re: Using dates during mail merge



You can add an ask field to collect the date at the start of the merge eg

{ ASK MyDate "Start Date" \d { Date \@ "dd/MM/yyyy} \o }{ SKIPIF {
Mergefield Date \@ "yyyyMMdd"} <> { REF MyDate \@ "yyyyMMdd "} }

The default date in that field is today's date, but it can be changed at the
prompt.

--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>

gjupp via OfficeKB.com wrote:
Yes, this is the comparison that I wish to make, preferably with a
space between month and year. And yes, we wish to make a 'not equal'
comparison.

I tried your suggestion, but the merge returned nil results. Word
date format (language 'English (UK)') was set to 'dd MMMM yyyy'
without ordinal. However, this may have no relevance.

Unless your suggested SKIPIF syntax can be modified, I suppose it
will not be possible to achieve my aim. If so, I shall continue to
use SKIPIF with the comparison date manually inserted at each merge.
This will be crude, but the method will work.

Many thanks indeed for your advice. It is very useful.



Peter Jamieson wrote:
You mean compare with things that are in your data source like

7th February2008
1st March2008

etc?

As long as you can use date and numeric field switches that generate
precisely the date format you need to compare with, you should be
able to use a simlar technique, e.g.

{ SKIPIF "{ MERGEFIELD mydatetext }" <> "{ DATE \@"D" \*Ordinal }{
DATE \@" MMMMYYYY" }" }

Haven't tried it myself though, and at best you will only be able to
do exact comparisons (equal or not equal), not determine whether one
date is before the other.

Many thanks indeed. This works fine. However, to go one step
further: Is it
[quoted text clipped - 11 lines]

Many thanks in anticipation.


.



Relevant Pages

  • Re: How to remove automatically some pages?
    ... Word MVP web site http://word.mvps.org ... separately without the extra character. ... I used the macro to the big MailMerge output file and it ...
    (microsoft.public.word.newusers)
  • Re: How to remove automatically some pages?
    ... Word MVP web site http://word.mvps.org ... pages using tha macro from you. ... separately without the extra character. ...
    (microsoft.public.word.newusers)
  • Re: How to remove automatically some pages?
    ... Please tell me where is your e-mail address on your web site. ... Word MVP web site http://word.mvps.org ... separately without the extra character. ... After the process of MailMerging I delete the "extra" pages using the macro from ...
    (microsoft.public.word.newusers)
  • Re: How to remove automatically some pages?
    ... Best regards ... Please tell me where is your e-mail address on your web site. ... Word MVP web site http://word.mvps.org ... After the process of MailMerging I delete the "extra" pages using the macro from ...
    (microsoft.public.word.newusers)
  • Re: Word closing down
    ... Graham Mayor - Word MVP ... Word MVP web site http://word.mvps.org ... emptied the Template folder (including the subfolders Document Themes ...
    (microsoft.public.word.docmanagement)

Loading