Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
{If } doesn't work
I am trying to create a date field which inserts the CreateDate or where
applicable the SaveDate. This is to avoid having new docs from templates opening with zeros and 'x's prior to saving, which happens if there's a savedate. I have put this into a field but it will not work. { IF { SAVEDATE } { CREATEDATE } { SAVEDATE /@ "ddMMMMyyyy" } {CREATEDATE /@ "ddMMMMyyyy" } } Using Office 2007 and Vista. Thanks! |
#2
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
{If } doesn't work
Try this:
{ IF { SAVEDATE \# "0" } = 0 "{ CREATEDATE /@ "ddMMMMyyyy" }" "{ SAVEDATE /@ "ddMMMMyyyy" }" } -- Stefan Blom Microsoft Word MVP "Deejay" wrote: I am trying to create a date field which inserts the CreateDate or where applicable the SaveDate. This is to avoid having new docs from templates opening with zeros and 'x's prior to saving, which happens if there's a savedate. I have put this into a field but it will not work. { IF { SAVEDATE } { CREATEDATE } { SAVEDATE /@ "ddMMMMyyyy" } {CREATEDATE /@ "ddMMMMyyyy" } } Using Office 2007 and Vista. Thanks! |
#3
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
{If } doesn't work
You will need switches(and the slashes the right way round) to make this
work {IF {Savedate \@ "yyyyMMdd"} {Createdate \@ "yyyyMMdd"} "{Savedate \@ "ddMMMMyyyy"}" "{Createdate \@ "ddMMMMyyyy"}"} See http://www.gmayor.com/formatting_word_fields.htm -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org Deejay wrote: I am trying to create a date field which inserts the CreateDate or where applicable the SaveDate. This is to avoid having new docs from templates opening with zeros and 'x's prior to saving, which happens if there's a savedate. I have put this into a field but it will not work. { IF { SAVEDATE } { CREATEDATE } { SAVEDATE /@ "ddMMMMyyyy" } {CREATEDATE /@ "ddMMMMyyyy" } } Using Office 2007 and Vista. Thanks! |
#4
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
{If } doesn't work
It might work better with the slashes the right way round?
-- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org Stefan Blom wrote: Try this: { IF { SAVEDATE \# "0" } = 0 "{ CREATEDATE /@ "ddMMMMyyyy" }" "{ SAVEDATE /@ "ddMMMMyyyy" }" } I am trying to create a date field which inserts the CreateDate or where applicable the SaveDate. This is to avoid having new docs from templates opening with zeros and 'x's prior to saving, which happens if there's a savedate. I have put this into a field but it will not work. { IF { SAVEDATE } { CREATEDATE } { SAVEDATE /@ "ddMMMMyyyy" } {CREATEDATE /@ "ddMMMMyyyy" } } Using Office 2007 and Vista. Thanks! |
#5
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
{If } doesn't work
Of course! Thanks for noticing.
-- Stefan Blom Microsoft Word MVP "Graham Mayor" wrote in message ... It might work better with the slashes the right way round? -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org Stefan Blom wrote: Try this: { IF { SAVEDATE \# "0" } = 0 "{ CREATEDATE /@ "ddMMMMyyyy" }" "{ SAVEDATE /@ "ddMMMMyyyy" }" } I am trying to create a date field which inserts the CreateDate or where applicable the SaveDate. This is to avoid having new docs from templates opening with zeros and 'x's prior to saving, which happens if there's a savedate. I have put this into a field but it will not work. { IF { SAVEDATE } { CREATEDATE } { SAVEDATE /@ "ddMMMMyyyy" } {CREATEDATE /@ "ddMMMMyyyy" } } Using Office 2007 and Vista. Thanks! |
#6
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
{If } doesn't work
Thank you both. Graham's code returns "SAVEDATE" while Stefan's (with the
right switches) returns 'Error! Too many picture switches defined' "Graham Mayor" wrote: You will need switches(and the slashes the right way round) to make this work {IF {Savedate \@ "yyyyMMdd"} {Createdate \@ "yyyyMMdd"} "{Savedate \@ "ddMMMMyyyy"}" "{Createdate \@ "ddMMMMyyyy"}"} See http://www.gmayor.com/formatting_word_fields.htm -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org Deejay wrote: I am trying to create a date field which inserts the CreateDate or where applicable the SaveDate. This is to avoid having new docs from templates opening with zeros and 'x's prior to saving, which happens if there's a savedate. I have put this into a field but it will not work. { IF { SAVEDATE } { CREATEDATE } { SAVEDATE /@ "ddMMMMyyyy" } {CREATEDATE /@ "ddMMMMyyyy" } } Using Office 2007 and Vista. Thanks! |
#7
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
{If } doesn't work
Thank you both. Graham's code returns "SAVEDATE" while Stefan's (with the
right switches) returns 'Error! Too many picture switches defined' "Graham Mayor" wrote: You will need switches(and the slashes the right way round) to make this work {IF {Savedate \@ "yyyyMMdd"} {Createdate \@ "yyyyMMdd"} "{Savedate \@ "ddMMMMyyyy"}" "{Createdate \@ "ddMMMMyyyy"}"} See http://www.gmayor.com/formatting_word_fields.htm -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org Deejay wrote: I am trying to create a date field which inserts the CreateDate or where applicable the SaveDate. This is to avoid having new docs from templates opening with zeros and 'x's prior to saving, which happens if there's a savedate. I have put this into a field but it will not work. { IF { SAVEDATE } { CREATEDATE } { SAVEDATE /@ "ddMMMMyyyy" } {CREATEDATE /@ "ddMMMMyyyy" } } Using Office 2007 and Vista. Thanks! |
#8
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
{If } doesn't work
In the code I suggested, did you remember the quotation marks? Did you
put spaces between the first SAVEDATE field and the equal sign? If you still can't get it to work, try using \@ "M" instead of \# "0": { IF { SAVEDATE \@ "M" } = 0 "{ CREATEDATE \@ "ddMMMMyyyy" }" "{ SAVEDATE \@ "ddMMMMyyyy" }" } -- Stefan Blom Microsoft Word MVP "Deejay" wrote in message ... Thank you both. Graham's code returns "SAVEDATE" while Stefan's (with the right switches) returns 'Error! Too many picture switches defined' "Graham Mayor" wrote: You will need switches(and the slashes the right way round) to make this work {IF {Savedate \@ "yyyyMMdd"} {Createdate \@ "yyyyMMdd"} "{Savedate \@ "ddMMMMyyyy"}" "{Createdate \@ "ddMMMMyyyy"}"} See http://www.gmayor.com/formatting_word_fields.htm -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org Deejay wrote: I am trying to create a date field which inserts the CreateDate or where applicable the SaveDate. This is to avoid having new docs from templates opening with zeros and 'x's prior to saving, which happens if there's a savedate. I have put this into a field but it will not work. { IF { SAVEDATE } { CREATEDATE } { SAVEDATE /@ "ddMMMMyyyy" } {CREATEDATE /@ "ddMMMMyyyy" } } Using Office 2007 and Vista. Thanks! |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Insert File (Range) does not work on different Work Stations | Mailmerge | |||
How to put Military work into Civilian work resumes? | Microsoft Word Help | |||
Make Work work properly on flat panels rotated 90deg | Page Layout | |||
my sound has decided not to work, what do i check to get it work | Microsoft Word Help | |||
Open for editing doesn't work on word. How do I get this to work? | Microsoft Word Help |